our $fakeeditorenv = 'DGIT_FAKE_EDITOR_QUILT';
-sub quiltify_dpkg_commit ($$$$) {
- my ($patchname,$title,$author,$msg) = @_;
+sub quiltify_dpkg_commit ($$$;$) {
+ my ($patchname,$author,$msg, $xinfo) = @_;
+ $xinfo //= '';
mkpath '.git/dgit';
my $descfn = ".git/dgit/quilt-description.tmp";
open O, '>', $descfn or die "$descfn: $!";
+ $msg =~ s/\s+$//g;
$msg =~ s/\n/\n /g;
$msg =~ s/^\s+$/ ./mg;
print O <<END or die $!;
-Description: $title
- $msg
+Description: $msg
Author: $author
-
+$xinfo
---
END
quiltify_dpkg_commit "auto-$version-$headref-$time",
(getfield $clogp, 'Maintainer'),
- "Automatically generated patch ($clogp->{Version})",
+ "Automatically generated patch ($clogp->{Version})\n".
"Last (up to) $ncommits git changes, FYI:\n\n". $msg;
}