Take the 2-minute tour ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

If I were feeling insufficiently geekish on any particular day, and thus found the GUI Chess App to lack an appropriate amount of tech credibility, is there a way to play chess on my Mac from the command line?

share|improve this question
    
With or without AI? And are you just gonna keep pieces position memorized? –  Gerry Nov 29 '12 at 2:39

1 Answer 1

up vote 8 down vote accepted

Yes! The OS X Chess app relies on the sjeng engine, which has a command line version. Type /Applications/Chess.app/Contents/Resources/sjeng.ChessEngine and press enter to play:

enter image description here

Make moves with the coordinates of the origin and destination you want: e1e4 moves the piece at e1 to e4.

Sjeng doesn't take any command line arguments, but you can edit the config file (stored in /Applications/Chess.app/Contents/Resources/sjeng.rc). This will probably mess with your settings in the GUI Chess app; make a backup before editing.

share|improve this answer
    
It's worth noting that running this app may create files such as "bug_LE.lrn", "losers_LE.lrn", "standard_LE.lrn", and "suicide_LE.lrn" on your system. These files are safe to delete. –  Kyle Cronin Dec 9 '12 at 4:25

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.