Last active
March 24, 2016 07:41
-
-
Save caiguanhao/34f6e89b18df3fdca4d2 to your computer and use it in GitHub Desktop.
iPhone on sale notification
This file contains hidden or 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
while :; do \ | |
curl -Ls 'http://www.apple.com/cn/shop/buy-iphone/iphone-se/64gb-金色' | \ | |
grep -q '暂无供应' && \ | |
sleep 10 || { \ | |
printf 'iPhone is OK to buy right now' | \ | |
wechat-notify --raw 'oBjSswsfgSvA6FlrR0rszh5eThhI@CGH' && \ | |
break; \ | |
}; done | |
while :; do \ | |
curl -Ls 'http://www.apple.com/cn/shop/goto/iphone_se/select' | \ | |
grep -q 'be back soon' && \ | |
sleep 10 || { \ | |
printf 'iPhone is OK to buy right now' | \ | |
wechat-notify --raw 'oBjSswsfgSvA6FlrR0rszh5eThhI@CGH' && \ | |
break; \ | |
}; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment