From d833b697cbd9e0b743b79242209c78651845f559 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 26 Aug 2013 16:36:23 +0100 Subject: [PATCH] Improve error message for non-fast-forward push. Closes: #720896. --- debian/changelog | 1 + dgit | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index d5507459..a30e4690 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 f582be0e..71b04230 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;". -- 2.30.2