Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # This script is intended to test ebay coupons from BigLion.
- # Is quantity of released coupons changed or not?
- # If number changes from 9518, then program will beep from speakers.
- #!/bin/bash
- while true
- do
- curl -s -o 1.html http://www.biglion.ru/deals/ebay-80/ &
- sleep 5
- d1=$(date)
- d2=$(cat 1.html | grep "купонов" | awk -F"<div>" '{print $2}' | awk -F"<span>" '{print $1}')
- echo "There are $d2 coupons to $d1 date."
- if [ $d2 != 9518 ]; then
- (sleep 2;killall speaker-test)&
- speaker-test -f 540 -p 1 -t sine >/dev/null 2>&1
- echo "WARNING! Coupons quantity changed!"
- else
- echo "Coupons quantity is still same :("
- fi
- done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement