1) Set your system preferences to start your computer at a specific time.
2) enter a crontab entry to execute a specific shell script 1 min after startup.
3) modify the shell script to open specific web pages. (make sure your script is executable)
4) Enjoy your automated mac.
I wrote an crontab and shell script to make this work. I use it daily. This way my mac gets my favorite web pages around 6:00 am and they are open for me when I start my machine for work around 8:00 am or later.
01 06 1-31 1-12 0-6 /Users/Henry/hwperl/daily.sh
That is my crontab entry. (google how to edit crontab. Your just telling your computer to execute this little program every day. )
http://developer.apple.com/DOCUMENTATION/Darwin/Reference/ManPages/man5/crontab. 5.html
This is the contents of daily.sh. (I LIke horoscopes and news)
a) (Copy from #! to EOF and save this to a script called daily.sh)
b) chmod +x daily.sh from the command line to make your script executable.
#!/bin/sh
osascript <<EOF>
property target_1 : "http://astrocenter.astrology.msn.com/msn/MyCareer.aspx?When=0&Af=-1000&VS="
property target_2 : "http://astrocenter.astrology.msn.com/msn/MyToday.aspx?Af=-1000&VS="
property target_3 : "http://www.chron.com/content/chronicle/horoscope/index.html"
property target_4 : "http://www.click2houston.com/horoscopes/756538/detail.html"
property target_5 : "http://news.google.com/"
property target_6 : "http://my.bbc.com/"
property target_7 : "http://www.click2houston.com/index.html"
property target_8 : "http://www.click2weather.com/index.html"
property target_9 : "http://www.eastrolog.com/daily-horoscope.php?args=cancer&days=0"
property target_10 : "http://www.lucknet.com/signes/cancers.htm"
property target_11 : "http://www.uclick.com/client/dmn/el/"
property target_12 : "http://www.slashdot.org"
property target_13 : "http://www.chron.com/"
property target_14 : "http://www.cnn.com/"
property target_15 : "http://www.foxnews.com/"
tell application "Safari" to open location target_1
tell application "Safari" to open location target_2
tell application "Safari" to open location target_3
tell application "Safari" to open location target_4
tell application "Safari" to open location target_5
tell application "Safari" to open location target_6
tell application "Safari" to open location target_7
tell application "Safari" to open location target_8
tell application "Safari" to open location target_9
tell application "Safari" to open location target_10
tell application "Safari" to open location target_11
tell application "Safari" to open location target_12
tell application "Safari" to open location target_13
tell application "Safari" to open location target_14
tell application "Safari" to open location target_15
EOF
references:
http://forum.maccast.com/index.php?showtopic=8844&hl=
Last thing to do is select system preferences => energy saver => schedule and tell the mac to turn on at a specific time of day. Your crontab entry should be scheduled to start about a minute after your computer starts.
Now your mac will fetch your web pages automatically!
Message was edited by Host