summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Jackson <ijackson@chiark.greenend.org.uk>2013-08-26 16:36:23 +0100
committerIan Jackson <ijackson@chiark.greenend.org.uk>2013-08-26 16:36:23 +0100
commitd833b697cbd9e0b743b79242209c78651845f559 (patch)
tree570012fed1b5fe8a6ba716bcc53fe89c1327635e
parent2c84b46d621bb5908bbfc64b9fcb12c30ab6b4a2 (diff)
Improve error message for non-fast-forward push. Closes: #720896.
-rw-r--r--debian/changelog1
-rwxr-xr-xdgit5
2 files changed, 5 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index d550745..a30e469 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ dgit (0.12) unstable; urgency=low
* Cope with packages with epoch. Closes: #720897.
* Add Closes line for #720595 to changelog entry for 0.11.
+ * Improve error message for non-fast-forward push. Closes: #720896.
--
diff --git a/dgit b/dgit
index f582be0..71b0423 100755
--- a/dgit
+++ b/dgit
@@ -984,7 +984,10 @@ sub cmd_push {
git_fetch_us();
}
if (fetch_from_archive()) {
- is_fast_fwd(lrref(), 'HEAD') or die;
+ is_fast_fwd(lrref(), 'HEAD') or
+ fail "dgit push: HEAD is not a descendant".
+ " of the archive's version.\n".
+ "$us: To overwrite it, use git-merge -s ours ".lrref().".";
} else {
$new_package or
fail "package appears to be new in this suite;".