diff options
author | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2016-12-15 00:54:21 +0000 |
---|---|---|
committer | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2016-12-19 16:58:57 +0000 |
commit | a99b94f7071fb3d3db2d679af5a736627ef10102 (patch) | |
tree | 7558abe2dd5764bf7ba7035ad8545768a2d7e5b9 /dgit | |
parent | 2d8ed57a73f0b8cc4ca31e60f85b24d4f6437075 (diff) |
By default, generate a DEP-14 tag as well as a dgit archive/* tag
Even in non-split-view quilt modes. Closes:#844129.
This breaks one of the test suite test cases, so disable it there.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Diffstat (limited to 'dgit')
-rwxr-xr-x | dgit | 35 |
1 files changed, 34 insertions, 1 deletions
@@ -69,6 +69,8 @@ our $rmchanges; our $overwrite_version; # undef: not specified; '': check changelog our $quilt_mode; our $quilt_modes_re = 'linear|smash|auto|nofix|nocheck|gbp|dpm|unapplied'; +our $dodep14tag; +our $dodep14tag_re = 'want|no|always'; our $split_brain_save; our $we_are_responder; our $initiator_tempdir; @@ -3674,7 +3676,21 @@ sub push_tagwants ($$$$) { TfSuffix => '-maintview', View => 'maint', }; - } + } elsif ($dodep14tag eq 'no' ? 0 + : $dodep14tag eq 'want' ? access_cfg_tagformats_can_splitbrain + : $dodep14tag eq 'always' + ? (access_cfg_tagformats_can_splitbrain or fail <<END) +--dep14tag-always (or equivalent in config) means server must support + both "new" and "maint" tag formats, but config says it doesn't. +END + : die "$dodep14tag ?") { + push @tagwants, { + TagFn => \&debiantag_maintview, + Objid => $dgithead, + TfSuffix => '-dgit', + View => 'dgit', + }; + }; foreach my $tw (@tagwants) { $tw->{Tag} = $tw->{TagFn}($cversion, access_nomdistro); $tw->{Tfn} = sub { $tfbase.$tw->{TfSuffix}.$_[0]; }; @@ -6095,6 +6111,15 @@ sub parseopts () { } elsif (m/^--overwrite=(.+)$/s) { push @ropts, $_; $overwrite_version = $1; + } elsif (m/^--dep14tag$/s) { + push @ropts, $_; + $dodep14tag= 'want'; + } elsif (m/^--no-dep14tag$/s) { + push @ropts, $_; + $dodep14tag= 'no'; + } elsif (m/^--always-dep14tag$/s) { + push @ropts, $_; + $dodep14tag= 'always'; } elsif (m/^--delayed=(\d+)$/s) { push @ropts, $_; push @dput, $_; @@ -6279,6 +6304,14 @@ if (!defined $quilt_mode) { $quilt_mode = $1; } +if (!defined $dodep14tag) { + local $access_forpush; + $dodep14tag = access_cfg('dep14tag', 'RETURN-UNDEF') // 'want'; + $dodep14tag =~ m/^($dodep14tag_re)$/ + or badcfg "unknown dep14tag setting \`$dodep14tag'"; + $dodep14tag = $1; +} + $need_split_build_invocation ||= quiltmode_splitbrain(); if (!defined $cleanmode) { |