From: Ramkumar Ramachandra <artagnon@gmail.com>
To: Git List <git@vger.kernel.org>
Cc: Junio C Hamano <gitster@pobox.com>
Subject: [PATCH] commit: correct advice about aborting a cherry-pick
Date: Fri, 26 Jul 2013 23:42:00 +0530 [thread overview]
Message-ID: <1374862320-22637-1-git-send-email-artagnon@gmail.com> (raw)
When a cherry-pick results in an empty commit, git prints:
The previous cherry-pick is now empty, possibly due to conflict resolution.
If you wish to commit it anyway, use:
git commit --allow-empty
Otherwise, please use 'git reset'
The last line is plain wrong in the case of a ranged pick, as a 'git
reset' will fail to remove $GIT_DIR/sequencer, failing a subsequent
cherry-pick or revert. Change the advice to:
git cherry-pick --abort
Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
---
Another candidate for maint?
I'd also really like to squelch this with an advice.* variable; any
suggestions?
builtin/commit.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/builtin/commit.c b/builtin/commit.c
index 003bd7d..1b213f7 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -64,7 +64,10 @@ N_("The previous cherry-pick is now empty, possibly due to conflict resolution.\
"\n"
" git commit --allow-empty\n"
"\n"
-"Otherwise, please use 'git reset'\n");
+"Otherwise, use:\n"
+"\n"
+" git cherry-pick --abort\n"
+"\n");
static const char *use_message_buffer;
static const char commit_editmsg[] = "COMMIT_EDITMSG";
--
1.8.4.rc0.1.g8f6a3e5.dirty
next reply other threads:[~2013-07-26 18:15 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-26 18:12 Ramkumar Ramachandra [this message]
2013-07-26 19:16 ` [PATCH] commit: correct advice about aborting a cherry-pick Jeff King
2013-07-26 21:17 ` Ramkumar Ramachandra
2013-07-26 21:24 ` Jeff King
2013-07-26 21:27 ` Ramkumar Ramachandra
2013-07-26 21:37 ` Jonathan Nieder
2013-07-26 21:40 ` Jeff King
2013-07-26 22:43 ` Jeff King
2013-07-26 23:05 ` Jeff King
2013-07-26 23:08 ` Jonathan Nieder
2013-07-26 23:19 ` Jeff King
2013-07-26 23:39 ` Jeff King
2013-07-27 8:07 ` Ramkumar Ramachandra
2013-07-29 15:18 ` Junio C Hamano
2013-07-29 15:23 ` Jeff King
2013-07-29 15:48 ` Junio C Hamano
2013-07-29 15:15 ` Junio C Hamano
2013-07-27 8:19 ` Ramkumar Ramachandra
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1374862320-22637-1-git-send-email-artagnon@gmail.com \
--to=artagnon@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).