Re: [RFC PATCH] commit -v: strip diffs and submodule shortlogs from the commit message

2013-11-18 Thread Junio C Hamano
Jeff King p...@peff.net writes: I found this hard to parse, I think because of the keeping (why would I not keep it?), and because you are talking about lines above and below. It is not as accurate to say: # -- 8 # Everything below this line will be

Re: [RFC PATCH] commit -v: strip diffs and submodule shortlogs from the commit message

2013-11-17 Thread Jeff King
On Sat, Nov 16, 2013 at 07:22:29PM -0500, Eric Sunshine wrote: /* Truncate the message just before the diff, if any. */ if (verbose) { - p = strstr(sb.buf, \ndiff --git ); - if (p != NULL) - strbuf_setlen(sb, p - sb.buf +

Re: [RFC PATCH] commit -v: strip diffs and submodule shortlogs from the commit message

2013-11-17 Thread Jens Lehmann
Am 17.11.2013 10:09, schrieb Jeff King: diff --git a/builtin/commit.c b/builtin/commit.c index 6ab4605..091a6e7 100644 --- a/builtin/commit.c +++ b/builtin/commit.c @@ -1602,9 +1602,9 @@ int cmd_commit(int argc, const char **argv, const char *prefix) /* Truncate the message just

Re: [RFC PATCH] commit -v: strip diffs and submodule shortlogs from the commit message

2013-11-16 Thread Eric Sunshine
On Sat, Nov 16, 2013 at 5:52 PM, Jens Lehmann jens.lehm...@web.de wrote: When using the '-v' option of git commit the diff added to the commit message temporarily for editing is stripped off after the user exited the editor by searching for \ndiff --git and truncating the commmit message