Running xBoard from command line

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Rebel, chrisw

CheckersGuy
Posts: 273
Joined: Wed Aug 24, 2016 9:49 pm

Running xBoard from command line

Post by CheckersGuy »

Hey,

I was setting up a google cloud instance the other day and did install xBoard. However, the xBoard -noGUI (and xBoard -noGUI=true) option didn't work at all. I always get the warning "cannot open display".

Did anyone get this to work or is this option bugged ?

Greetings

Robin
User avatar
MikeB
Posts: 4889
Joined: Thu Mar 09, 2006 6:34 am
Location: Pen Argyl, Pennsylvania

Re: Running xBoard from command line

Post by MikeB »

CheckersGuy wrote:Hey,

I was setting up a google cloud instance the other day and did install xBoard. However, the xBoard -noGUI (and xBoard -noGUI=true) option didn't work at all. I always get the warning "cannot open display".

Did anyone get this to work or is this option bugged ?

Greetings

Robin
The option -noGUI is misleading. What it means is that the chessboard and clock is not updated during a game, it was design for micro bullet game in the order of 10 seconds/game. Ideally you would use this during a match or tournament where you might run 8 to 12 games at once (depending on your hardware) . Just click the "trn" file to start another instance. But you still have the GUI sans any games updates. The option works find under macOS.

Also, I believe you can use it through the commandline, but when I used to run a match using that feature, I would set the match up using the GUI, and then simply edit "trn" file , adding in -noGUI option. Then click the "trn" file and it would start the match with th eGUI , but the moves and clock updates would not be displayed on the chessboard. HGM can probably add more to this discussion .
User avatar
hgm
Posts: 27808
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Running xBoard from command line

Post by hgm »

Indeed, the -noGUI option perhaps promises more than it actually does. When I introduced it I saw it as a first step towards a pure command-line tool. It turned out to be quite difficult, however, to get completely rid of the widget platforms, as these are also used for the internal multi-tasking and timing functions.

I considered the possibility to provide a command-line version as a separate 'noBoard' build (in addition to the Xaw and GTK builds), which would use pthreads for multi-tasking and 'alarm' system calls for timing. I never got to actually doing that. Especially since someone pointed out that there apparently exists a 'dummy' X-server, which one can install on display-less systems. This then provides the same API as a real X-server, so that programs like XBoard (Xaw version) would run without complaints, the GUI functions all turned into no-ops.