SVN devscripts commit: r551 - in trunk: debian scripts
Adam D. Barratt
adam-guest at alioth.debian.org
Sat Mar 10 02:16:28 CET 2007
Author: adam-guest
Date: 2007-03-10 01:16:28 +0000 (Sat, 10 Mar 2007)
New Revision: 551
Modified:
trunk/debian/changelog
trunk/scripts/bts.pl
Log:
Handle new status / maintainer mboxes
Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog 2007-03-08 21:48:44 UTC (rev 550)
+++ trunk/debian/changelog 2007-03-10 01:16:28 UTC (rev 551)
@@ -64,8 +64,11 @@
* debc: Add support for udebs, based on a patch from Frans Pop
(Closes: #404952)
* svnpath: is GPLv2 or later
+ * bts:
+ - handle new status / maintainer mbox links when downloading bugs
+ - use bugs.d.o/mbox:NNNN to download the mbox
- -- Adam D. Barratt <debian-bts at adam-barratt.org.uk> Thu, 8 Mar 2007 21:47:01 +0000
+ -- Adam D. Barratt <debian-bts at adam-barratt.org.uk> Sat, 10 Mar 2007 01:12:38 +0000
devscripts (2.9.27) unstable; urgency=low
Modified: trunk/scripts/bts.pl
===================================================================
--- trunk/scripts/bts.pl 2007-03-08 21:48:44 UTC (rev 550)
+++ trunk/scripts/bts.pl 2007-03-10 01:16:28 UTC (rev 551)
@@ -1980,6 +1980,11 @@
# This always needs refreshing, as it does change as the bug
# changes
}
+ elsif ($cachemode eq 'full' and $msg =~ /^(status|maint)mbox$/) {
+ $bug2filename{$msg} = $filename;
+ # Always need refreshing, as they could change each time the
+ # bug does
+ }
next unless exists $bug2filename{$msg};
@@ -2033,7 +2038,7 @@
}
init_agent() unless $ua;
- my $request = HTTP::Request->new('GET', $btscgiurl . "bugreport.cgi?bug=$thing;mbox=yes");
+ my $request = HTTP::Request->new('GET', $btsurl . "mbox:$thing");
my $response = $ua->request($request);
if ($response->is_success) {
my $content_length = defined $response->content ?
@@ -2284,6 +2289,10 @@
my $ref = $3;
$ref =~ s/&(?:amp;)?/;/g; # normalise all hrefs
$ref =~ s/;archive=(yes|no)\b//;
+ $ref =~ s/%3D/=/g;
+ # 20070310 ADB Work-around a BTS bug. We should probably remove
+ # this if the BTS gets fixed
+ $ref =~ s/=mbox/;mbox=yes/g;
if ($ref =~ /;msg=(\d+)$/) {
$msg = $1;
@@ -2297,6 +2306,14 @@
$msg = 'mbox';
$filename = "$bug.mbox";
}
+ elsif ($ref =~ /^;mbox=yes;mboxstatus=yes$/) {
+ $msg = 'statusmbox';
+ $filename = "$bug.status.mbox";
+ }
+ elsif ($ref =~ /^;mboxmaint=yes;mbox=yes$/) {
+ $msg = 'maintmbox';
+ $filename = "$bug.maint.mbox";
+ }
elsif ($ref eq '') {
return undef;
}
More information about the Devscripts-devel
mailing list