On 4/24/19 11:01 AM, Andrius Merkys wrote: > Hello, > > I want to package unversioned source. AFAIK, it should be possible to > have timestamp of the last tarball change in lieu of upstream version. I > am wondering if it would be possible to write uscan rules to extract the > timestamp and download the upstream tarball by analyzing the following > HTML excerpt (taken from [1]): > > <img src="/icons/compressed.gif" alt="[ ]"><a > href="reference-structures.tar.gz">reference-structures.tar.gz</a>2013-03-12 > 12:16 6.4M > > where the "reference-structures.tar.gz" is the tarball I want and > "2013-03-12" is the timestamp. > > Thanks in advance, > Andrius > > [1] https://www2.mrc-lmb.cam.ac.uk/personal/pemsley/coot/dependencies/ > > -- > Andrius Merkys > Vilnius University Institute of Biotechnology, SaulÄ—tekio al. 7, room V325 > LT-10257 Vilnius, Lithuania >
Hi Andrius, have you found a solution? I managed to craft the following d/watch: https://paste.debian.net/hidden/7ed83d37/ version=4 opts="pagemangle=s/(?:.*)(@PACKAGE@)(\.tar\.gz).*?(\d{4}-\d{2}-\d{2})(?:.*)/<a href="$1_$3$2">/g, \ uversionmangle=s/(?:.*)\.([\d-]*)/$1/, \ downloadurlmangle=s{(.*)(\.tar\.gz)}{https://www2.mrc-lmb.cam.ac.uk/personal/pemsley/coot/dependencies/@PACKAGE@$2}" \ https://www2.mrc-lmb.cam.ac.uk/personal/pemsley/coot/dependencies (@PACKAGE@@ANY_VERSION@@ARCHIVE_EXT@) I am pretty sure one can optimize it, but this seem to work too. Best, Alex