From a99b94f7071fb3d3db2d679af5a736627ef10102 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Thu, 15 Dec 2016 00:54:21 +0000 Subject: 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 --- dgit | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) (limited to 'dgit') diff --git a/dgit b/dgit index 1a23d1a..7996227 100755 --- a/dgit +++ b/dgit @@ -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 < \&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) { -- cgit v1.2.3