summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2018-06-27 13:29:04 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2018-06-27 13:31:05 +0100
commit0c285f61c99f278e9cf6b121037bbce8f9d0e3b9 (patch)
tree9b2704c70fbb49b3837f53420a46c850109e1835
parent05babd80e5414230f567ac26bf3d5118aa595320 (diff)
dgit(7): Add discussion of quilt fixup error messages
And add cross-references to dgit(1) and the actual error. Somewhat apropos of #842614. Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
-rw-r--r--debian/changelog3
-rwxr-xr-xdgit3
-rw-r--r--dgit.15
-rw-r--r--dgit.784
4 files changed, 94 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index 724f784..ccb0d2b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -10,6 +10,9 @@ dgit (5.3~) unstable; urgency=medium
Improvements:
* Better message formatting when --overwrite may be needed,
and a note about first dgit push in dgit(1). Closes:891031.
+ * dgit(7): Add discussion of quilt fixup error messages,
+ and add cross-references to dgit(1) and the actual error.
+ Somewhat apropos of #842614.
--
diff --git a/dgit b/dgit
index 1559a02..bfc168c 100755
--- a/dgit
+++ b/dgit
@@ -5400,7 +5400,8 @@ sub quiltify ($$$$) {
print STDERR "$us: ", $reportnot->($notp), "\n";
}
print STDERR "$us: $_\n" foreach @$failsuggestion;
- fail "quilt fixup naive history linearisation failed.\n".
+ fail
+ "quilt history linearisation failed. Search \`quilt fixup' in dgit(7).\n".
"Use dpkg-source --commit by hand; or, --quilt=smash for one ugly patch";
} elsif ($quilt_mode eq 'smash') {
} elsif ($quilt_mode eq 'auto') {
diff --git a/dgit.1 b/dgit.1
index e54ab43..f15fecf 100644
--- a/dgit.1
+++ b/dgit.1
@@ -334,6 +334,11 @@ so dgit quilt-fixup can be useful in its own right.
To always use dgit's own patch generator
instead of git-debrebase make-patches,
pass --git-debrebase=true to dgit.
+
+See
+.B FORMAT 3.0 (QUILT)
+in
+.BR dgit(7) .
.TP
\fBdgit import-dsc\fR [\fIsub-options\fR] \fI../path/to/.dsc\fR [\fB+\fR|\fB..\fR]branch
Import a Debian-format source package,
diff --git a/dgit.7 b/dgit.7
index 7ad5aba..0d43ee0 100644
--- a/dgit.7
+++ b/dgit.7
@@ -284,6 +284,13 @@ pushing. The only thing you need to know is that dgit build, sbuild,
etc., may make new commits on your HEAD. If you're not a quilt user
this commit won't contain any changes to files you care about.
+Simply commiting to source files
+(whether in debian/ or not, but not to patches)
+will result in a branch that dgit quilt-fixup can linearise.
+Other kinds of changes,
+including editing patches or merging,
+cannot be handled this way.
+
You can explicitly request that dgit do just this fixup, by running
dgit quilt-fixup.
@@ -292,6 +299,83 @@ If you are a quilt user you need to know that dgit's git trees are
directory (which is used by quilt to record which patches are
applied). If you want to manipulate the patch stack you probably want
to be looking at tools like git-dpm.
+
+.SS quilt fixup error messages
+When dgit's quilt fixup fails, it prints messages like this:
+
+.EX
+dgit: base trees orig=5531f03d8456b702eab6 o+d/p=135338e9cc253cc85f84
+dgit: quilt differences: src: == orig ## gitignores: == orig ##
+dgit: quilt differences: HEAD ## o+d/p HEAD ## o+d/p
+starting quiltify (multiple patches, linear mode)
+
+dgit: error: quilt fixup cannot be linear. Stopped at:
+dgit: 696c9bd5..84ae8f96: changed debian/patches/test-gitignore
+.EE
+
+.TP
+.B orig
+is an import of the .orig tarballs dgit found,
+with the debian/ directory from your HEAD substituted.
+This is a git tree object, not a commit:
+you can pass its hash to git-diff but not git-log.
+
+.TP
+.B o+d/p
+is another tree object,
+which is the same as orig
+but with the patches from debian/patches applied.
+
+.TP
+.B HEAD
+is of course your own git HEAD.
+
+.TP
+.B quilt differences
+shows whether each of the these trees differs from the others
+(i) in upstream files excluding .gitignore files;
+(ii) in upstream .gitignore files.
+.B ==
+indicates equality;
+.B ##
+indicates inequality.
+.LP
+dgit quilt-fixup --quilt=linear walks commits
+backwards from your HEAD
+trying to construct a linear set of additional patches,
+starting at the end.
+It hopes to eventually find an ancestor
+whose tree is identical to o+d/p in all upstream files.
+
+In the error message,
+696c9bd5..84ae8f96
+is the first commit child-parent edge
+which cannot be sensibly be
+either ignored, or turned into a patch in debian/patches.
+In this example, this is because
+it itself changes files in debian/patches,
+indicating that something unusual is going on
+and that continuing is not safe.
+But you might also see other kinds of troublesome commit or edge.
+
+Your appropriate response depends on the cause and the context.
+If you have been freely merging your git branch
+and do not need need a pretty linear patch queue,
+you can use
+.B --quilt=smash
+(or use the
+.B 1.0
+or
+.B single-debian-patch
+source formats; see
+.BR dpkg-source(1) .)
+If you want a pretty linear series,
+and this message is unexpected,
+it can mean that you have unwittingly committed changes
+that are not representable by dpkg-source (such as some mode changes).
+Or maybe you just forgot a necessary
+.B --quilt=
+option.
.SH SPLIT VIEW QUILT MODE
When working with git branches intended
for use with the `3.0 (quilt)' source format