WebInspector Code
Status: Beta
Brought to you by:
mateuszjarus
File | Date | Author | Commit |
---|---|---|---|
etc | 2010-04-08 | mateuszjarus | [r5] Changed directory structure. |
src | 2010-04-14 | mateuszjarus | [r9] Completed documentation. |
.project | 2010-04-04 | mateuszjarus | [r1] First WebInspector release :) |
.pydevproject | 2010-04-04 | mateuszjarus | [r1] First WebInspector release :) |
INSTALL | 2010-04-14 | mateuszjarus | [r7] New main webinspector script. |
LICENCE | 2010-04-04 | mateuszjarus | [r1] First WebInspector release :) |
README | 2010-04-14 | mateuszjarus | [r8] Completed documentation. |
setup.py | 2010-04-05 | mateuszjarus | [r3] Changed modules names. |
WebInspector is a python console program that periodically checks a list of websites for changes and updates. If such an update is detected, selected by the user program (or programs) is executed. By default it's just a web browser. To run the program with the default settings, type: python web_inspector.py from the main directory structure (it works on Linux as well as on Windows). WebInspector uses the following HTTP headers to check the site updates: Last-Modified/If-Modified-Since and ETag/If-None-Match. If none of these headers are accepted by the HTTP server, WebInspector calculates the MD5 sum of the website. The sites that should tracked must be listed in the etc/sites file. Every website address should be provided in a new line. Moreover, you can specify a third-party program (or programs) that should be executed once a change on a site is detected. The full path to that software should follow the website address after a comma and space. Correct format of the sites file is given below: http://sourceforge.net/projects/webinspector/, /usr/bin/firefox http://sourceforge.net/projects/webinspector/ http://www.mysimplewebsite.com/, /usr/bin/playwave test.wav, /usr/bin/firefox http://www.mysimplewebsite.com/ Always remember about the "http://" prefix! This file tells the program to track two websites. If any change is noticed in the first of them, webbrowser is started (firefox in this case) with that webpage open. Please notice that the website address after the path to firefox is an argument of that program, not another software to open (there's no comma between them). If any change is detected in the second website, a .wav file is played at first and then firefox is executed. When WebInspector is executed with the default settings, it tracks all the websites provided in the etc/sites file every 30 seconds. To change that time you can use the -t or --time switch: python web_inspector.py -t 10 In such case WebInspector will check the sites every 10 seconds. With the -v or --verbose switch you can make the program write additional information about its work. Using -c or --config use can change the path to the sites configuration file. This run configuration: python web_inspector.py -c ~/new_sites will make WebInspector to use ~/new_sites file to check for websites that should be tracked. Run the program with the -h or --help switch to see this information again :). To stop WebInspector, press ctrl + c. Please note that this program is still in it's first phase of development and needs much work to show its full potential. Mateusz Jarus <mateusz.jarus@gmail.com> http://sourceforge.net/projects/webinspector/