This question already has an answer here:
I'm looking for a command-line tool to let two chess engines play a game or a tournament against each other. The tool should support UCI and/or the xboard protocol and it should allow to save the game as a PGN.
I could only find GUI programs for that purpose. Aren't there any commandline tools that can do that job?