Bash script to monitor a website and send iOS push notification upon changes.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
website_diff
LICENSE
README.md

README.md

Website Diff with iOS Push Notifications Via Prowl

This bash script monitors a webpage for changes. When changes are found, it sends a push notification via Prowl and archives the new version of the web page. This is a simple script that downloads the url, peforms a diff and reports on any changes.

Related blog post

Installation

  1. Clone or download this repo.
  2. Install prowl's dependencies, and prowl:
  3. sudo apt-get install libwww-perl -y
  4. sudo perl -MCPAN -e 'install Bundle::LWP' (accept the defaults)
  5. wget http://www.prowlapp.com/static/prowl.pl
  6. chmod +x prowl.pl
  7. Move prowl.pl to the website_diff/ directory
  8. Edit the website_diff.sh file and configure, by adding your prowl API key and the path to the script (including the website_diff directory).
  9. Add the urls you wish to monitor to website_diff.sh
  10. Create a cronjob to execute website_diff.sh at the desired fequency.

Usage

The first time a url is scraped, it will send an alert. After that, alerts will only be sent if changes are detected. When a change is detected, the new version of the url is archived in the archive folder.

The prowl push message includes a url argument, so all you have to do is swipe when you receive the message and you will be redirected to the webpage.

Credits

Thanks to this post for the inspiration: http://bhfsteve.blogspot.com/2013/03/monitoring-web-page-for-changes-using.html