Console/SSH/X: How to tell?

Marc Lanctot lanctot-yfeSBMgouQgsA/PxXw9srA at public.gmane.org
Fri Jun 19 20:01:00 UTC 2009


On Fri, 19 Jun 2009 15:54:33 -0400
Dave Germiquet <davegermiquet-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org> wrote:

> I'm wondering if you can use the $DISPLAY variable...
> 
> If the $DISPLAY variable is empty your in a shell.. if the $DISPLAY
> variable has :0 or 0:0.1 you know you can open an xterminal window.
> 

Yeah so far that's my best solution, but I would like for pal to be
executed when I login remotely through ssh as well (just not when I use
scp or execute remote commands via ssh).

Marc

-- 
Any code of your own that you haven't looked at for six or more months
might as well have been written by someone else.
  -- Eagleson's law
--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list