diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-06-05 02:03:13 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-06-05 02:03:13 +0200 |
commit | 00c0e40f020581ff010a3efd96243bf0ae726fb0 (patch) | |
tree | b2da71224902e8bae1834bf1baf91a7dbc34f20a /builtin | |
parent | Merge branch 'kn/ref-filter-branch-list' into maint (diff) | |
parent | interpret-trailers: honor the cut line (diff) | |
download | git-00c0e40f020581ff010a3efd96243bf0ae726fb0.tar.xz git-00c0e40f020581ff010a3efd96243bf0ae726fb0.zip |
Merge branch 'bm/interpret-trailers-cut-line-is-eom' into maint
"git interpret-trailers", when used as GIT_EDITOR for "git commit
-v", looked for and appended to a trailer block at the very end,
i.e. at the end of the "diff" output. The command has been
corrected to pay attention to the cut-mark line "commit -v" adds to
the buffer---the real trailer block should appear just before it.
* bm/interpret-trailers-cut-line-is-eom:
interpret-trailers: honor the cut line
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/commit.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/commit.c b/builtin/commit.c index 1d805f5da8..8d1cac0629 100644 --- a/builtin/commit.c +++ b/builtin/commit.c @@ -1735,7 +1735,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix) if (verbose || /* Truncate the message just before the diff, if any. */ cleanup_mode == CLEANUP_SCISSORS) - wt_status_truncate_message_at_cut_line(&sb); + strbuf_setlen(&sb, wt_status_locate_end(sb.buf, sb.len)); if (cleanup_mode != CLEANUP_NONE) strbuf_stripspace(&sb, cleanup_mode == CLEANUP_ALL); |