Author: adsb
Date: 2008-10-29 19:45:06 +0000 (Wed, 29 Oct 2008)
New Revision: 1677

Modified:
   trunk/debian/changelog
   trunk/scripts/debdiff.pl
Log:
debdiff: Correctly handle hyphenated distribution names when generating
a diff against the previous version of the package. (Closes: #503950)

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog      2008-10-27 23:18:36 UTC (rev 1676)
+++ trunk/debian/changelog      2008-10-29 19:45:06 UTC (rev 1677)
@@ -4,6 +4,8 @@
   * debchange: Don't attempt to automatically determine if the current
     changelog is an NMU if an alternative changelog location was specified
     using the CHANGELOG environment variable.
+  * debdiff: Correctly handle hyphenated distribution names when generating
+    a diff against the previous version of the package. (Closes: #503950)
   * getbuildlogs:
     + Apply some patches from Jörg Sommer (Closes: #496065)
       - Unescape %7Es in log URLs to allow explicitly searching for 

Modified: trunk/scripts/debdiff.pl
===================================================================
--- trunk/scripts/debdiff.pl    2008-10-27 23:18:36 UTC (rev 1676)
+++ trunk/scripts/debdiff.pl    2008-10-29 19:45:06 UTC (rev 1677)
@@ -267,10 +267,12 @@
 # If no file is given, assume that we are in a source directory
 # and try to create a diff with the previous version
 if(@ARGV == 0) {
+    my $name_pat = qr/[-+0-9a-z.]/i;
+
     fatal "Can't read file: debian/changelog" unless -r "debian/changelog";
     open CHL, "debian/changelog";
     while(<CHL>) {
-       if(/^(.+)\s\((\d+:)?(.+)\)\s(\w+)\;\surgency=.+$/) {
+       if(/^(\w$name_pat*)\s\((\d+:)?(.+)\)\s($name_pat+)\;\surgency=.+$/) {
            unshift @ARGV, "../".$1."_".$3.".dsc";
            $guessed_version++;
        }



-- 
To unsubscribe, send mail to [EMAIL PROTECTED]

Reply via email to