From: Ian Jackson Date: Mon, 26 Aug 2013 15:36:23 +0000 (+0100) Subject: Improve error message for non-fast-forward push. Closes: #720896. X-Git-Tag: debian/0.12~3 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=d833b697cbd9e0b743b79242209c78651845f559;p=dgit.git Improve error message for non-fast-forward push. Closes: #720896. --- 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;".