July 2, 2016 - A simple webpage monitor that sends an email if website's content changes.
What we see depends mainly on what we look for.- John Lubbock
The algorithm for this project is:
Enter a URL:
Let’s pretend the previous hash of the content at https://hightower.space/projects/ was:abcdef198f00b204e9800998ecf8427e
If the new hash of the URL content is different, an alert will be sent to the email address passed into the script and the new hash will be recorded. In our example, the new hash (d41d8cd98f00b204e9800998ecf8427e) is different from the old hash (abcdef198f00b204e9800998ecf8427e) so an alert would be sent.
If the hash of a URL’s content is the same as it was the last time the script was run, nothing will be updated.
usage: page_monitor.py [-h] email_address email_account_password
Monitor a webpage for changes to its content and send alerts if there are any changes.
email_address an email address from which I can send updates if a webpage changes
email_account_password the password for the email address so that I can send notifications if a webpage changes
- -h, –help show this help message and exit
You can learn more here: https://gitlab.com/fhightower/page-monitor.