From 69edfee88ecb0aeb8b954c31b5937f8f7e997072 Mon Sep 17 00:00:00 2001 From: Christoph Korn Date: Fri, 15 Nov 2013 18:18:12 +0100 Subject: [PATCH] Add upstream watcher for jwltief The download page just uses id's in the link. The version is only shown as text. Parse this version and add it to the URL of the download page. This will 404 but you will be on the right way. --- jwltief.py | 12 ++++++++++++ update.sh | 1 + 2 files changed, 13 insertions(+) create mode 100644 jwltief.py diff --git a/jwltief.py b/jwltief.py new file mode 100644 index 0000000..5da45ec --- /dev/null +++ b/jwltief.py @@ -0,0 +1,12 @@ +#!/usr/bin/python +import urllib2 +import re + +r=urllib2.urlopen("http://games.aleva.com.br/jwltief/") +html=r.read() + +finder=re.compile('(?:.*)Jwltief (?P[\d\.]+) Linux \(Debian/Ubuntu\)(?:.*)', re.DOTALL) +m=finder.match(html) +if m: + v=m.group('version') + print "%s"%(v,v) diff --git a/update.sh b/update.sh index 9fb5289..93c00d9 100644 --- a/update.sh +++ b/update.sh @@ -4,6 +4,7 @@ python warsow.py > warsow.html 2> warsow.log python snowstorm.py > snowstorm.html 2> snowstorm.log python wakeonplan.py > wakeonplan.html 2> wakeonplan.log python jag.py > jag.html 2> jag.log +python jwltief.py > jwltief.html 2> jwltief.log python nikki.py > nikki.html 2> nikki.log python legends.py > legends.html 2> legends.log python the-powder-toy.py > the-powder-toy.html 2> the-powder-toy.log