Q: Running a script when AirPort network is found?

Markus Hitter mah at jump-ing.de
Thu Oct 11 01:14:49 PDT 2007


Am 11.10.2007 um 09:41 schrieb Alex Satrapa:

> From what I've read of launchd, I can get the script to start at  
> some specific time, or in response to some external activity  
> (connection to a port, or presence of a file in a nominated  
> directory/folder).

Yes, and if the MacBook is asleep at the scheduled time, ths script  
will run a few minutes after the next wake. So, scheduling the script  
a few times a day should do it. Make the script to quit if it finds  
it's self in the wrong network. The script is run as the user  
issueing the launchctl, so "launchctl load ..." and "sudo launchctl  
load ..." both work, but make a difference.


Markus

- - - - - - - - - - - - - - - - - - -
Dipl. Ing. Markus Hitter
http://www.jump-ing.de/






More information about the MacOSX-admin mailing list