mercredi 25 avril 2007

HINT For UNIX

| Q: anybody got a one-line command line script that will set your
| display for remote usage without having to go through the
| who | grep uid and setenv commands?

# for C shell
setenv DISPLAY `who am i | cut -d '(' -f 2 | cut -d ')' -f 1`:0.0

# for Korn shell (but not for historic Bourne shell)
export DISPLAY=`who am i | cut -d '(' -f 2 | cut -d ')' -f 1`:0.0



source : http://www.cs.utk.edu/~shuford/terminal/xterm_news.txt

Aucun commentaire: