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: Finding my $DISPLAY programatically.



> > Some of the remote systems are quite old and don't all have ssh
> 
> Is there any reason why you can't install ssh on these ancient machines?

Jeremy, asking this poor fellow to run around and find an SSH server
to run on 10-year-old SunOS machines (if that's what he has -- it's
what I have, so I'm projecting here), then install it on all of those
machines (thousands?), when he obviously has no need for it, just so
that Apple's X11 will continue to work for him on newer Apple
machines, is a bit much.

> Is there a way to programmatically translate the launchd style DISPLAY  
> (i.e. /tmp/launch-idaF18/:0) into a usable DISPLAY (i.e.  
> 172.16.1.1:0.0)?

How about

   #!/bin/sh

   MYIP=`ifconfig -a | grep 'inet' | grep 'broadcast' | awk '{print $2}'`
   echo `echo $DISPLAY | sed -e "s;^.*:;${MYIP}:;"`

??

Bill

 _______________________________________________
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: 
 >Finding my $DISPLAY programatically. (From: Robert Tillyard <email@hidden>)
 >Re: Finding my $DISPLAY programatically. (From: "Mark J. Reed" <email@hidden>)
 >Re: Finding my $DISPLAY programatically. (From: Robert Tillyard <email@hidden>)
 >Re: Finding my $DISPLAY programatically. (From: Jeremy Huddleston <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.