From 873877b3ec9f20ebfd8ca1b8365d68c0e1f296c1 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Fri, 10 Mar 2017 15:35:01 +0000 Subject: [PATCH] git-debrebase: wip comments --- git-debrebase | 46 +++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 41 insertions(+), 5 deletions(-) diff --git a/git-debrebase b/git-debrebase index ba990e74..1c902a26 100755 --- a/git-debrebase +++ b/git-debrebase @@ -115,10 +115,10 @@ sub get_commit ($) { return ($`,$'); } -sub D_DEB () { return 0x1; } -sub D_UPS () { return 0x2; } -sub D_PAT_ADD () { return 0x4; } -sub D_PAT_OTH () { return 0x8; } +sub D_DEB () { return 0x1; } # debian/ (not including debian/patches/) +sub D_UPS () { return 0x2; } # upstream files +sub D_PAT_ADD () { return 0x4; } # debian/patches/ extra patches at end +sub D_PAT_OTH () { return 0x8; } # debian/patches other changes our $rd = ".git/git-debrebase"; our $ud = "$rd/work"; @@ -130,12 +130,48 @@ sub commit_pr_info ($) { sub calculate_committer_authline () { my $c = cmdoutput @git, qw(commit-tree --no-gpg-sign -m), - 'XXX DUMMY COMMIT (git-debrebase)', "$basis:"; + 'DUMMY COMMIT (git-debrebase)', "$basis:"; my ($h,$m) = get_commit $c; $h =~ m/^committer .*$/m or confess "($h) ?"; return $&; } +# classify returns an info hash like this +# CommitId => $objid +# Hdr => # commit headers, including 1 final newline +# Msg => # commit message (so one newline is dropped) +# Tree => $treeobjid +# Type => (see below) +# Parents = [ { +# Ix => $index # ie 0, 1, 2, ... +# CommitId +# Differs => return value from get_differs +# IsOrigin +# IsDggitImport => 'orig' 'tarball' 'unpatched' 'package' (as from dgit) +# } ...] +# NewMsg => # commit message, but with any [dgit import ...] edited +# # to say "[was: ...]" +# +# Types: +# Packaging +# Upstream +# AddPatches +# Mixed +# Unknown +# +# Pseudomerge +# has additional entres in classification result +# Overwritten = [ subset of Parents ] +# Contributor = $the_remaining_Parent +# +# DgitImportUnpatched +# has additional entry in classification result +# OrigParents = [ subset of Parents ] +# +# BreakwaterUpstreamMerge +# has additional entry in classification result +# OrigParents = [ subset of Parents ] + sub classify ($) { my ($objid) = @_; -- 2.30.2