home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!noc.near.net!hri.com!spool.mu.edu!darwin.sura.net!sgiblab!nec-gw!nec-tyo!wnoc-tyo-news!scslwide!wsgw!wsservra!onoe
- From: dharding@pollux.lssec.bt.co.uk (Derek Harding)
- Newsgroups: fj.mail-lists.x-window
- Subject: Re: setting DISPLAY env variable
- Message-ID: <1992Dec21.223424.14550@sm.sony.co.jp>
- Date: 21 Dec 92 22:34:24 GMT
- Sender: onoe@sm.sony.co.jp (Atsushi Onoe)
- Distribution: fj
- Organization: BT D&P London
- Lines: 59
- Approved: michael@sm.sony.co.jp
-
- Date: 21 Dec 92 08:57:29 GMT
- Message-Id: <1992Dec21.085729.22936@lssec.bt.co.uk>
- Newsgroups: comp.windows.x
- References: <1gmgnoINN4bu@sol.deakin.OZ.AU>, <1go0ivINN93@gap.caltech.edu>
- Sender: xpert-request@expo.lcs.mit.edu
-
- In article <1go0ivINN93@gap.caltech.edu>, lindheim@hagar.ccsf (Jan Lindheim) writes:
- |> In article 1gmgnoINN4bu@sol.deakin.OZ.AU, rns@deakin.OZ.AU (Robert Sturrock) writes:
- |> >Hello,
- |> >
- |> >is there a way to set the DISPLAY variable to be the particular workstation
- |> >you are using inside ".bashrc". That is, I want every new xterm, for
- |> >whatever host I happen to be logging into, to have DISPLAY set to my
- |> >workstation. Note that my workstation will vary, so I can't just
- |> >hardwire
- |> >
- |> > export DISPLAY=workstation:0.0
- |> >
- |> >inside my .bashrc file.
- |> >
- |> >Thanks
- |> >
- |> >
- |> >Rob
- |>
- |> You can put something like:
- |>
- |> if ("`tty`" == "/dev/console") then
- |> echo `hostname`:0 > $HOME/.x11host
- |> else
- |> set X11HOST = (`cat $HOME/.x11host`)
- |> setenv DISPLAY $X11HOST
- |> endif
- |>
- I use the following command in my .twmrc (I use ksh) to run framemaker remotely. This
- works from any workstation since it uses the 'hostname' command to workout what machine
- I am on.
-
- Menu "Tools"
- {
- "Remote Frame (xxx) ..." ! "rsh xxx \"DISPLAY=`hostname`:0;export DISPLAY;\
- /tools/framemaker/bin/imaker\" &"
- .
- .
- .
- }
-
- Derek
- --
-
- +------------------------------------+----------------------------------------+
- | Derek Harding | |
- | London Engineering Centre, BT Labs | OpenWindows should be thrown |
- | PP 6/3, Room 616 151 Gower Street | out of one ! |
- | London WC1E 6BA | |
- | | Joke of the week: |
- | Tel: 071-728-7861 | We don't follow standards, we set |
- | Email: dharding@lssec.bt.co.uk | them - Sun Microsystems |
- +------------------------------------+----------------------------------------+
-