Hi,

fiddling with the watch file for 'asio', I recently found myself wanting
to check my uversionmangle pattern. However, uscan --debug didn't show
me the effects of my regexp.

With the attached simple patch, uscan lists the mangled version
determined from the upstream file (in braces). Provided on a "works for
me" basis, not much testing performed.

Regards

Markus Wanner
diff --git a/debian/changelog b/debian/changelog
index b69a646..771cace 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -8,6 +8,9 @@ devscripts (2.13.1) UNRELEASED; urgency=low
   [ Benjamin Drung ]
   * wnpp-check: Correct download links to fix regression from previous release.
 
+  [ Markus Wanner ]
+  * uscan.pl: more debug info to allow checking uversionmangle patterns.
+
  -- Benjamin Drung <[email protected]>  Tue, 19 Feb 2013 17:22:32 +0100
 
 devscripts (2.13.0) experimental; urgency=low
diff --git a/scripts/uscan.pl b/scripts/uscan.pl
index 8723fb4..9aef201 100755
--- a/scripts/uscan.pl
+++ b/scripts/uscan.pl
@@ -963,7 +963,7 @@ sub process_watchline ($$$$$$)
 	if (@hrefs) {
 	    if ($verbose) {
 		print "-- Found the following matching hrefs:\n";
-		foreach my $href (@hrefs) { print "     $$href[1]\n"; }
+		foreach my $href (@hrefs) { print "     $$href[1]\t($$href[0])\n"; }
 	    }
 	    if (defined $download_version) {
 		my @vhrefs = grep { $$_[0] eq $download_version } @hrefs;
@@ -1060,7 +1060,7 @@ sub process_watchline ($$$$$$)
 	if (@files) {
 	    if ($verbose) {
 		print "-- Found the following matching files:\n";
-		foreach my $file (@files) { print "     $$file[1]\n"; }
+		foreach my $file (@files) { print "     $$file[1]\t($$file[0])\n"; }
 	    }
 	    if (defined $download_version) {
 		my @vfiles = grep { $$_[0] eq $download_version } @files;
@@ -1588,7 +1588,7 @@ sub newest_dir ($$$$$) {
 	    @hrefs = Devscripts::Versort::versort(@hrefs);
 	    if ($debug) {
 		print "-- Found the following matching hrefs (newest first):\n";
-		foreach my $href (@hrefs) { print "     $$href[1]\n"; }
+		foreach my $href (@hrefs) { print "     $$href[1]\t($$href[0])\n"; }
 	    }
 	    my $newdir = $hrefs[0][1];
 	    # just give the final directory component

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
devscripts-devel mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/devscripts-devel

Reply via email to