Bug#807484: uscan: Add example for archlinux site

Osamu Aoki osamu at debian.org
Wed Dec 9 13:02:14 UTC 2015


Package: devscripts
Version: 2.15.9
Severity: wishlist
User: devscripts at packages.debian.org
Usertags: uscan

If people wish to write watch file for archlinux upstream package, what
to do is non-trivial:

https://projects.archlinux.org/svntogit/community.git/tree/trunk/PKGBUILD?h=packages/archlinux-xdg-menu

  https://wiki.archlinux.org/index.php/Arch_User_Repository
  https://wiki.archlinux.org/index.php/Arch_Build_System
  https://projects.archlinux.org/svntogit/packages.git/
  https://projects.archlinux.org/svntogit/community.git/

Its cgit and seem to have snapshot tar available.  Complicated.

Anyway, I found URL:
https://www.archlinux.org/packages/community/any/archlinux-xdg-menu/

If we arart from here
     <h2>archlinux-xdg-menu 0.7.6.2-2</h2>

This gave me a hint how to write watch file

Let's start from the following page.

https://projects.archlinux.org/svntogit/community.git/log/trunk?h=packages/archlinux-xdg-menu

This is a nice page to find out recent versions and if the latest version
is the one you know.  If newer version is identified to available, let's
download using the following URL

<a href="/svntogit/community.git/commit/trunk?h=packages/archlinux-xdg-menu&id=cc758a06c32147218cae5f79738a4232e0c56edc">upgpkg: archlinux-xdg-menu 0.7.6.2-2</a>

Hmmm.. either way, pagemangle is needed to pick version.  Then only the
latest version can be downloaded from

https://www.archlinux.org/packages/community/any/archlinux-xdg-menu/download/

Then rename tarball.

With downloadurlmangle and filenamemangle this is doable .... along

version=4
opts="pagemangle=...,downloadurlmangle=...,filenamemangle=..." \
https://www.archlinux.org/packages/community/any/archlinux-xdg-menu/ \
archlinux-xdg-menu\s+([\-\d\.])

Ugly but OK.  If there is an easier URL to use for download for each
version, this can be made better.

Osamu



More information about the devscripts-devel mailing list