|
|
An AppleScript to do IP-based mounting and indexing
There is a line that reads:
Split the line after the period and before the word "on."
I've done similar things based on IP address, but since my work IP is DHCP and relatively random, I check via regular expression, although checking via netmask would be just as usable. Applescript doesn't have all the juice needed for this, but if you augment with shell scripts, you can do quite a lot of things. I needed to modify my script for a special case where I traveled somewhere and the IP address I received made it appear that I was at home. I got around this by making a tweak to do a "one shot ping" of a system that should be always reachable on my home LAN in order to differentiate between being "home," "in the office," or "visiting." Doesn't that sound like network "locations?" [smile] I can think of some other interesting things that such a script can do, once it knows where you are:
As for the script presented, I honestly never considered turning Spotlight on the shares I mount. Silly me! (And great idea! I may add that to my own script!) |
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysNo new commentsLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.16 seconds |
|