# We make the git tag by hand because (a) that makes it easier
# to control the "tagger" (b) we can do remote signing
my $authline = clogp_authline $clogp;
- my @dtxinfo = @deliberatelies;
my $mktag = sub {
my ($tw) = @_;
tagger $authline
END
- if ($tw->{View} eq 'dgit') {
- print TO f_ <<ENDT, $package, $cversion, $clogsuite, $csuite
-%s release %s for %s (%s) [dgit]
-ENDT
- or confess "$!";
- unshift @dtxinfo, "--quilt=$quilt_mode" if madformat($format);
- unshift @dtxinfo, do_split_brain() ? "split" : "no-split"
- # rpush protocol 5 and earlier don't tell us
- unless $we_are_initiator && $protovsn < 6;
- my $dtxinfo = join(" ", "",@dtxinfo);
- print TO <<END or confess "$!";
+
+ my @dtxinfo = @deliberatelies;
+ unshift @dtxinfo, "--quilt=$quilt_mode" if madformat($format);
+ unshift @dtxinfo, do_split_brain() ? "split" : "no-split"
+ # rpush protocol 5 and earlier don't tell us
+ unless $we_are_initiator && $protovsn < 6;
+ my $dtxinfo = join(" ", "",@dtxinfo);
+ my $tag_metadata = <<END;
[dgit distro=$declaredistro$dtxinfo]
END
- foreach my $ref (sort keys %previously) {
- print TO <<END or confess "$!";
+ foreach my $ref (sort keys %previously) {
+ $tag_metadata .= <<END or confess "$!";
[dgit previously:$ref=$previously{$ref}]
END
- }
+ }
+
+ if ($tw->{View} eq 'dgit') {
+ print TO sprintf <<ENDT, $package, $cversion, $clogsuite, $csuite
+%s release %s for %s (%s) [dgit]
+ENDT
+ or confess "$!";
} elsif ($tw->{View} eq 'maint') {
- print TO f_ <<END, $package, $cversion, $clogsuite, $csuite,
+ print TO sprintf <<END, $package, $cversion, $clogsuite, $csuite;
%s release %s for %s (%s)
+
+END
+ print TO f_ <<END,
(maintainer view tag generated by dgit --quilt=%s)
END
$quilt_mode
} else {
confess Dumper($tw)."?";
}
+ print TO "\n", $tag_metadata;
close TO or confess "$!";