On Thu, Jul 28, 2005 at 10:55:03AM -0400, [EMAIL PROTECTED] wrote:
> How can I tell if I'm running under X in a shell script? If I'm in X, I
> want to start screen: screen -m -c /my/config/file. If I'm not under X,
> I want to start without the -m. It's an odd google to find the answer to
> thi
Write a script something like this, and call it "screen". Or call it
"myscreen". Or whatever...
#!/bin/sh
# if no DISPLAY variable, then we are not in X
# DISPLAY might not be the best environment variable to test for but
# it should work
if [ -z "$DISPLAY" ]; then
exec /usr/bin/screen blah
On Thu, Jul 28, 2005 at 10:55:03AM -0400, [EMAIL PROTECTED] wrote:
> How can I tell if I'm running under X in a shell script?
Check to see if $DISPLAY is set.
--
Andy Goth + [EMAIL PROTECTED] + http://ioioio.net/
___
screen-users mailing list
scr
On Thu, 28 Jul 2005 [EMAIL PROTECTED] wrote:
How can I tell if I'm running under X in a shell script? If I'm in X, I
want to start screen: screen -m -c /my/config/file. If I'm not under X,
I want to start without the -m. It's an odd google to find the answer to
this question, so your wisdom
How can I tell if I'm running under X in a shell script? If I'm in X, I
want to start screen: screen -m -c /my/config/file. If I'm not under X,
I want to start without the -m. It's an odd google to find the answer to
this question, so your wisdom is appreicated.
-judd maltin