Created
April 13, 2011 17:38
-
-
Save mdoff/917990 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#login i haslo do bramki http://smsfree.pl/ | |
smslogin="" | |
smspass="" | |
numer="" | |
msg="przyklad wiadomosci" | |
web="http://pb.mat.ug.edu.pl/analiza/" | |
curl $web -s > old | |
while true; | |
do | |
new=`curl "$web" -s` | |
old=`cat old` | |
if [ "$new" != "$old" ] ; then | |
echo poszlo | |
#sms! | |
curl -s -d "numer_global=$smslogin&password_global=$smspass" http://www.smsfree.pl/index.php -c ciastek.txt > /dev/null | |
curl -s -b ciastek.txt -d "what=sms&kody=48&numer=$numer&tariff=1&podpis=48+$smslogin+&submit=Przeslij sms\'a&text=$msg" http://www.smsfree.pl/index.php > /dev/null | |
rm ciastek.txt | |
rm old | |
break | |
fi | |
sleep 60 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment