public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] Can a script tell if it's running under X?
@ 2004-12-04 21:34 Kevin O'Gorman
  2004-12-04 21:43 ` Nick Rout
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Kevin O'Gorman @ 2004-12-04 21:34 UTC (permalink / raw
  To: gentoo-user

Is there a way for a script (bash, for instance) to know
if it's running under X, such as in an xterm or konsole?

I want to have scripts that run graphical tools if the
infrastructure is present, and text tools otherwise.
For me this is particularly useful for tools I don't use
all that often, and can forget that a graphical version
exists.

++ kevin

-- 
Go back to the top: I almost always top-post
Kevin O'Gorman, PhD

--
gentoo-user@gentoo.org mailing list


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2004-12-06  4:20 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-04 21:34 [gentoo-user] Can a script tell if it's running under X? Kevin O'Gorman
2004-12-04 21:43 ` Nick Rout
2004-12-06  2:07   ` cdemarco
2004-12-06  4:19     ` Iain Buchanan
2004-12-04 21:45 ` Matan Peled
2004-12-05  0:55   ` Bastian Balthazar Bux
2004-12-04 22:54 ` Peter Gordon
2004-12-05  0:22   ` Collins Richey
2004-12-05  7:31     ` Peter Gordon
2004-12-05 15:08       ` Collins Richey
2004-12-05  8:25   ` Uwe Thiem
2004-12-05  8:27   ` Marko Vallius

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox