chiark / gitweb /
Tag change: dgit: Fetch both old ane new format tags
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 24 Jul 2016 18:52:21 +0000 (19:52 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 31 Jul 2016 21:55:01 +0000 (22:55 +0100)
We are going to want to know about all of these.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
dgit

diff --git a/dgit b/dgit
index 45eef63..ba3a2e4 100755 (executable)
--- a/dgit
+++ b/dgit
@@ -1560,14 +1560,14 @@ sub git_fetch_us () {
     runcmd_ordryrun_local @git, qw(fetch -p -n -q), access_giturl(), @specs;
 
     my %here;
-    my $tagpat = debiantag('*',access_basedistro);
+    my @tagpats = debiantags('*',access_basedistro);
 
-    git_for_each_ref("refs/tags/".$tagpat, sub {
+    git_for_each_ref([map { "refs/tags/$_" } @tagpats], sub {
        my ($objid,$objtype,$fullrefname,$reftail) = @_;
        printdebug "currently $fullrefname=$objid\n";
        $here{$fullrefname} = $objid;
     });
-    git_for_each_ref(lrfetchrefs."/tags/".$tagpat, sub {
+    git_for_each_ref([map { lrfetchrefs."/tags/".$_ } @tagpats], sub {
        my ($objid,$objtype,$fullrefname,$reftail) = @_;
        my $lref = "refs".substr($fullrefname, length lrfetchrefs);
        printdebug "offered $lref=$objid\n";