//View Tip #894
» Debian device driver check and report
» Stream YouTube videos directly to your media player
Similar Tips
» Backup delicious bookmarks» Debian device driver check and report
» Stream YouTube videos directly to your media player
Latest tips by RSS
Click here to subscribe
Follow Shell-Fu on Twitter
Click here to follow
Follow Shell-Fu on identi.ca
Click here to follow
This script will run check a for the Ubuntu 9.10 launch once every 5 mins and let you know when it's available:
while [ 1 ]; do if [ -z "`curl -I "http://cdimage.ubuntu.com/releases/9.10/release/"|grep "404"`" ]; then kdialog --msgbox "9.10 Released"; exit; fi; sleep 300; done
Comments
Add your comment
Better to search for a positive, than to exclude one specific negative. 404 isn't the only error. The server could be down!!
while [ 1 ];
do if [ ! -z "`curl -I "http://cdimage.ubuntu.com/rele … ease/"|grep "HTTP/1.1 200 OK"`" ];
then
zenity --warning --text "9.10 Released"
exit;
fi;
sleep 300;
done
while [ 1 ];
do if [ ! -z "`curl -I "http://cdimage.ubuntu.com/rele … ease/"|grep "HTTP/1.1 200 OK"`" ];
then
zenity --warning --text "9.10 Released"
exit;
fi;
sleep 300;
done
Posted 2009-10-29 04:58:21
One of the worst tips ever.
cron was made for exactly that...
cron was made for exactly that...
Posted 2009-10-29 05:30:58
Martin:
Surely cron was made for recurring tasks with no end condition? I would have said this is exactly what 'while' was made for!
Surely cron was made for recurring tasks with no end condition? I would have said this is exactly what 'while' was made for!
Posted 2009-10-29 08:53:09
i believe you are a good writer, but have you erver thought to write some special artcals for peopel who likes shopping very much.
Posted 2010-07-15 22:52:10
You could do the same thing by grepping the slashdot homepage.
Posted 2010-08-16 23:25:14


while [ 1 ]; do if [ -z "`curl -I "http://cdimage.ubuntu.com/rele … ease/"|grep "404"`" ];
then zenity --warning --text "9.10 Released"; exit; fi; sleep 300; done