Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations)



Ben Byer wrote:
[]
How about this?

# If no display has been specified, deduce local display number from X11 process.
if [ "$DISPLAY" = "" ]; then
export DISPLAY = `ps auxww | grep $USER | egrep '(Xauthority|/Applications/Utilities/X11.app/Contents/MacOS/X11 .*:[0-9]+$)' | grep -v grep | sed 's/^.*\(:[0-9][0-9]*\)$/\1/'` fi


(If you know where that code came from, you get a cookie!)

Smells of matlab.

--
Martin

_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/x11-users/email@hidden

This email sent to email@hidden
References: 
 >Re: Explanation of X implementations (From: John Bassett <email@hidden>)
 >Re: Explanation of X implementations (From: Ben Byer <email@hidden>)
 >Re: Explanation of X implementations (From: "Ambrose Li" <email@hidden>)
 >The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: Eric Gouriou <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: "Ambrose Li" <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: "Andrew J. Hesford" <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: "Ambrose Li" <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: Ben Byer <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: "Nathaniel Gray" <email@hidden>)
 >Re: The meaning(s) of $DISPLAY (was Re: Explanation of X implementations) (From: Ben Byer <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.