From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103734,674f735b36ac5ffe X-Google-Attributes: gid103734,public X-Google-Thread: 1070f0,674f735b36ac5ffe X-Google-Attributes: gid1070f0,public X-Google-Thread: fee84,674f735b36ac5ffe X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-10-08 02:45:04 PST Path: bga.com!news.sprintlink.net!redstone.interpath.net!ddsw1!news.kei.com!MathWorks.Com!news.duke.edu!news-feed-1.peachnet.edu!gatech!gt-news!cc.gatech.edu!azhao From: azhao@cc.gatech.edu (Q. Alex Zhao) Newsgroups: comp.windows.x,comp.sys.sun.admin,comp.unix.osf.osf1 Subject: Re: Any script for setting the DISPLAY variable? Followup-To: comp.windows.x Date: 7 Oct 1994 12:07:27 -0400 Organization: GVU Center, College of Computing, Georgia Tech. Distribution: usa Message-ID: <373rnv$jtm@oakmont.cc.gatech.edu> References: <35s3f6$4es@bigdog.fred.net> <36uhtn$5du@mrnews.mro.dec.com> <373qnd$id@netserver.univ-lille1.fr> NNTP-Posting-Host: oakmont.cc.gatech.edu NNTP-Posting-User: azhao Xref: bga.com comp.windows.x:12354 comp.sys.sun.admin:17099 comp.unix.osf.osf1:3943 Sean J. Anaya (sanaya@vrl.nmsu.edu) wrote: ] This should work: ] #Set the default X server. ] #if ($?DISPLAY == 0) then ] # if ($?REMOTEHOST) then ] # setenv DISPLAY ${REMOTEHOST}:0.0 ] # else ] # setenv DISPLAY :0.0 ] # endif ] #endif The above approach will work on SGI IRIX and Solaris 2.x etc. machines, but not on Solaris 1. In article <373qnd$id@netserver.univ-lille1.fr>, dubus@omega.univ-lille1.fr (Georges Dubus) writes: ] On most of Unix systems the command (shell script) named "xon" can be used ] for this purpose: ] This command is provided with X11 distrib "xon" will NOT work if the "hostname" command on your machine doesn't give the full host name (such as that on SunOS 4.1.3), and the remote host which you are trying to connect is outside your domain or doesn't recognize the host name unless it's a full name... And "xon" has only one way of dealing with auth, which is not to deal with it -- turn "xhost" on. "xrsh" (could be found on "ftp.x.org") provides a lot of options besides correctly setting up the $DISPLAY variable and passing auth keys. -- = Q. Alex Zhao ~{0"UT~} ! Graphics, Visualization & Usability Center Email: azhao@cc.gatech.edu ! College of Computing FAX: 404-853-9378 ! Georgia Institute of Technology Lab: 404-894-9636 ! Atlanta, Georgia 30332-0280