{"thread":{"id":"24403","subject":"[PATCH 3/4] revert: don't print \"Finished one cherry-pick.\" if commit failed","startedAt":"2010-07-13T23:28:14Z","lastAt":"2010-07-15T22:42:51Z","messageCount":2,"participants":["Christian Couder","Jonathan Nieder"],"isPatch":true,"patchVersion":1,"patchTotal":4},"messages":[{"id":"145612","messageId":"20100713232816.7738.202.chriscool@tuxfamily.org","threadId":"24403","inReplyTo":null,"subject":"[PATCH 3/4] revert: don't print \"Finished one cherry-pick.\" if commit failed","fromName":"Christian Couder","fromEmail":"chriscool@tuxfamily.org","sentAt":"2010-07-13T23:28:14Z","receivedAt":"2010-07-13T23:28:14Z","isPatch":true,"sender":{"key":"christian.couder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/208954?v=4"},"body":"\nSigned-off-by: Christian Couder <chriscool@tuxfamily.org>\n---\n builtin/revert.c |   17 +++++------------\n 1 files changed, 5 insertions(+), 12 deletions(-)\n\ndiff --git a/builtin/revert.c b/builtin/revert.c\nindex b84b5b8..ec931bd 100644\n--- a/builtin/revert.c\n+++ b/builtin/revert.c\n@@ -518,24 +518,17 @@ static int do_pick_commit(void)\n \t\t\tmebuf.buf, help_msg());\n \t\trerere(allow_rerere_auto);\n \t} else {\n-\t\tfprintf(stderr, \"Finished one %s.\\n\", mebuf.buf);\n+\t\tif (!no_commit)\n+\t\t\tres = run_git_commit(defmsg);\n+\t\tif (!res)\n+\t\t\tfprintf(stderr, \"Finished one %s.\\n\", mebuf.buf);\n \t}\n \n \tstrbuf_release(&mebuf);\n \tfree_message(&msg);\n-\n-\tif (res)\n-\t\treturn 1;\n-\n-\tif (!no_commit) {\n-\t\tres = run_git_commit(defmsg);\n-\t\tfree(defmsg);\n-\t\treturn res;\n-\t}\n-\n \tfree(defmsg);\n \n-\treturn 0;\n+\treturn res;\n }\n \n static void prepare_revs(struct rev_info *revs)\n-- \n1.7.2.rc1.215.g2dff2.dirty\n"},{"id":"145667","messageId":"20100715224251.GA7253@burratino","threadId":"24403","inReplyTo":"20100713232816.7738.202.chriscool@tuxfamily.org","subject":"Re: [PATCH 3/4] revert: don't print \"Finished one cherry-pick.\" if commit failed","fromName":"Jonathan Nieder","fromEmail":"jrnieder@gmail.com","sentAt":"2010-07-15T22:42:51Z","receivedAt":"2010-07-15T22:42:51Z","isPatch":true,"sender":{"key":"jrnieder@gmail.com","avatar":"https://avatars.githubusercontent.com/u/281595?v=4"},"body":"Christian Couder wrote:\n\n> Subject: revert: don't print \"Finished one cherry-pick.\" if commit failed\n\nThis and the previous one make the code much easier to read.\nSo for what it’s worth I like them.\n"}]}