Package: devscripts Version: 2.16.2~bpo8+1 Severity: wishlist File: /usr/bin/uscan Tags: patch
The @ANY_VERSION@ regex currently *requires* a leading hyphen/underscore intended to separate it from @PACKAGE@, but this limits its usefulness/general applicability - see [corsix-th] and [scummvm-tools] for examples. Unless this would brake some compatibility I'm not aware of, I propose it be made optional, as originally suggested in [#517637]. [#517637]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=517637#51 [corsix-th]: https://anonscm.debian.org/cgit/pkg-games/corsix- th.git/commit/?id=cba5757fe753e82af9d20d4c3670650707c60c7e [scummvm-tools]: https://anonscm.debian.org/cgit/pkg-games/scummvm- tools.git/commit/?id=617be034d41b07c598316be86ecff1bbcd448674 The attached patch makes the below simple change in the code and documentation, but it may need additional tests in `test_uscan_mangle` - I wasn't sure how to do this if it was necessary. - [-_](\d[\-+\.:\~\da-zA-Z]*) + [-_]?(\d[\-+\.:\~\da-zA-Z]*) -- Package-specific info: --- /etc/devscripts.conf --- --- ~/.devscripts --- DEBUILD_DPKG_BUILDPACKAGE_OPTS="-i -us -uc" DEBUILD_LINTIAN_OPTS="-i -I --show-overrides" DEBSIGN_KEYID="9F113609" -- System Information: Debian Release: 8.4 Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages devscripts depends on: ii dpkg-dev 1.17.26 ii libc6 2.19-18+deb8u4 ii perl 5.20.2-3+deb8u4 ii python3 3.4.2-2 pn python3:any <none> Versions of packages devscripts recommends: ii apt 1.0.9.8.3 ii at 3.1.16-1 ii curl 7.38.0-4+deb8u3 ii dctrl-tools 2.23 ii debian-keyring 2015.04.10 ii dput 0.9.6.4 ii equivs 2.0.9 ii fakeroot 1.20.2-1 ii file 1:5.22+15-2+deb8u1 ii gnupg 1.4.18-7+deb8u1 ii gnupg2 2.0.26-6 ii libdistro-info-perl 0.14 ii libencode-locale-perl 1.03-1 ii liblwp-protocol-https-perl 6.06-2 ii libsoap-lite-perl 1.11-1 ii liburi-perl 1.64-1 ii libwww-perl 6.08-1 ii lintian 2.5.42.1~bpo8+1 ii man-db 2.7.0.2-5 ii patch 2.7.5-1 ii patchutils 0.3.3-1 ii python3-debian 0.1.27 ii python3-magic 1:5.22+15-2+deb8u1 ii sensible-utils 0.0.9 ii strace 4.9-2 ii unzip 6.0-16+deb8u2 ii wdiff 1.2.2-1 ii wget 1.16-1 ii xz-utils 5.1.1alpha+20120614-2+b3 Versions of packages devscripts suggests: ii bsd-mailx [mailx] 8.1.2-0.20141216cvs-2 ii build-essential 11.7 pn cvs-buildpackage <none> pn debbindiff <none> pn devscripts-el <none> pn dose-extra <none> pn gnuplot <none> ii gpgv 1.4.18-7+deb8u1 ii libauthen-sasl-perl 2.1600-1 ii libfile-desktopentry-perl 0.07-1 ii libnet-smtp-ssl-perl 1.01-3 pn libterm-size-perl <none> ii libtimedate-perl 2.3000-2 pn libyaml-syck-perl <none> pn mozilla-devscripts <none> ii mutt 1.5.23-3 ii openssh-client [ssh-client] 1:6.7p1-5+deb8u2 ii svn-buildpackage 0.8.5+nmu1 ii w3m 0.5.3-19 -- no debconf information
>From db7fc2dfee0f5d9121a2cd78df51d1eced183d63 Mon Sep 17 00:00:00 2001 From: Phil Morrell <deb...@emorrp1.name> Date: Sat, 16 Apr 2016 18:01:46 +0100 Subject: [PATCH] uscan: make initial hyphen optional in @ANY_VERSION@ --- scripts/uscan.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/uscan.pl b/scripts/uscan.pl index 4b09b2e..e9f1d7a 100755 --- a/scripts/uscan.pl +++ b/scripts/uscan.pl @@ -256,7 +256,7 @@ F<debian/changelog> file. This is substituted by the legal upstream version regex (capturing). - [-_](\d[\-+\.:\~\da-zA-Z]*) + [-_]?(\d[\-+\.:\~\da-zA-Z]*) =item B<@ARCHIVE_EXT@> @@ -4147,7 +4147,7 @@ sub process_watchfile ($$$$) s/\\\\/\\/g if $watch_version==1; # Handle @PACKAGE@ @ANY_VERSION@ @ARCHIVE_EXT@ substitutions - my $any_version = '[-_](\d[\-+\.:\~\da-zA-Z]*)'; + my $any_version = '[-_]?(\d[\-+\.:\~\da-zA-Z]*)'; my $archive_ext = '(?i)\.(?:tar\.xz|tar\.bz2|tar\.gz|zip)'; my $signature_ext = $archive_ext . '\.(?:asc|pgp|gpg|sig)'; s/\@PACKAGE\@/$package/g; -- 2.1.4