1 |
As some may know, I'm working on euscan, and currently euscan only use |
2 |
CPV and SRC_URI to find new upstream versions. |
3 |
This works well if upstream url and version scheme is sane or if |
4 |
upstream has an API for that (rubygem, pypi, pecl, pear), but it's far |
5 |
from optimal. |
6 |
|
7 |
Debian use a specific file for that: debian/watch and it looks like |
8 |
that (for media-plugins/vdr-softdevice): |
9 |
|
10 |
opts=downloadurlmangle=s/prdownload/download/ \ |
11 |
http://developer.berlios.de/project/showfiles.php?group_id=2051 \ |
12 |
http://prdownload.berlios.de/softdevice/vdr-softdevice-(.+).tgz |
13 |
|
14 |
opts specify some options to mangle the final url, and then there is a |
15 |
list of url to scan. man uscan for more informations. |
16 |
|
17 |
Currently, if you run euscan on this package, it doesn't work at all: |
18 |
http://euscan.iksaif.net/package/media-plugins/vdr-softdevice/ |
19 |
1/ it's hosted on gentoo mirrors, and scanning them takes too long |
20 |
because all files are in the same directory |
21 |
2/ the url doesn't contain the version |
22 |
|
23 |
So, to help euscan (and other tools) for some package, I think we |
24 |
could introduce some hints in metadata.xml. This would extend the |
25 |
existing "upstream" element: |
26 |
|
27 |
<upstream> |
28 |
<version-scan downloadurlmangle="s/prdownload/download/">http://developer.berlios.de/project/showfiles.php?group_id=2051 |
29 |
\ |
30 |
http://prdownload.berlios.de/softdevice/vdr-softdevice-(.+).tgz</version-scan> |
31 |
</upstream> |
32 |
|
33 |
The format is not defined yet, but it would probably look like |
34 |
debian/watch, that would allow to write a script to import (valid) |
35 |
debian/watch files into associated metadata.xml when needed. |
36 |
|
37 |
One other thing, metadata.xml already contain a remote-id tag, which |
38 |
would be very great to help euscan do its job, but a lot of package |
39 |
are lacking it: |
40 |
- Should we patch repoman to scan SRC_URI and issue a warning when it |
41 |
looks like an URI that match a well known remote-id |
42 |
- Should we write a script to update metadata.xml ? It would be easy |
43 |
for rubygem, pypi and pear packages. |
44 |
|
45 |
Any comment ? Objections ? Ideas ? |
46 |
|
47 |
Thanks, |
48 |
|
49 |
-- |
50 |
Corentin Chary |
51 |
http://xf.iksaif.net |