Created
December 18, 2019 12:45
-
-
Save sandipndev/a9e21e144573d3924255727b7c89acf2 to your computer and use it in GitHub Desktop.
[WIN-10 only!] Makaut Website Changed Notifier
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
from time import sleep | |
from urllib.request import urlopen | |
from win10toast import ToastNotifier | |
url = "http://www.makautexam.net" | |
toaster = ToastNotifier() | |
with urlopen(url) as handle: | |
prev_html = handle.read().decode() | |
while True: | |
with urlopen(url) as handle: | |
html = handle.read().decode() | |
if html != prev_html: | |
toaster.show_toast("Makaut Website Changed", "Check " + url) | |
break | |
sleep(5) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment