xdisplay is a little script which can help to keep track of where you are and set your default X DISPLAY.
Version: 1.0xdisplay is a little script which can help to keep track of where you are and set your default X DISPLAY. If your DISPLAY is set, it will be returned, but if it is not, this will return the last known value. Use this in environments where you want your display to automatically get set whenever you log into remote machines. Appropriate stderr messages are output when invoked so that you are aware of your settings.
Operating System: Linux
This display value gets stored in ~/.xdisplay. To use, put this in your path somewhere, say ~/bin and:
in csh, do: setenv DISPLAY `xdisplay`
in sh, do: export DISPLAY=`xdisplay`