i had a go at making a script to download a .txt file for local weather - i have put this in /startup to downloads on each boot, what i would like to do now is have this script automatically run every hour to download an updated weather .txt file.
Here is the script in /startup
Code: Select all
#!/bin/sh
if [ /root/EGXE.TXT ];then
rm /root/EGXE.TXT
fi
wget http://weather.noaa.gov/pub/data/observations/metar/decoded/EGXE.TXT
if [ /root/Startup/EGXE.TXT ];then
mv EGXE.TXT /root/EGXE.TXT
fi
Code: Select all
#!/bin/sh
xmessage -buttons "Exit" -fg "#59FF00" -bg "#000000" -title Weather -center -file /root/EGXE.TXT -timeout 10
I really don't know anything about writing scripts so any help with A. writing them correctly and B. how to run the one in /startup every hour would be much appreciated.
thanks.