summaryrefslogtreecommitdiff
path: root/builtin/fmt-merge-msg.c
diff options
context:
space:
mode:
authorRalf Thielow <ralf.thielow@gmail.com>2013-04-07 17:25:43 +0200
committerJunio C Hamano <gitster@pobox.com>2013-04-07 09:28:29 -0700
commit9927ebed1966be260afb3579781d5b4a9ee4a029 (patch)
treeef9b36aea6391a5bc2ceaa97a128718cbce3db24 /builtin/fmt-merge-msg.c
parent239222f587ed06f96d90dd71c66d80a2b1e3dc9f (diff)
downloadgit-9927ebed1966be260afb3579781d5b4a9ee4a029.tar.gz
fmt-merge-msg: respect core.commentchar in people credits
Commit eff80a9 (Allow custom "comment char") introduced a custom comment character for commit messages but forgot to use it in people credits which can be a part of a commit message. With this commit, the custom comment character is also used in people credits. Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/fmt-merge-msg.c')
-rw-r--r--builtin/fmt-merge-msg.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/builtin/fmt-merge-msg.c b/builtin/fmt-merge-msg.c
index b49612f0ce..4bf167ad8a 100644
--- a/builtin/fmt-merge-msg.c
+++ b/builtin/fmt-merge-msg.c
@@ -287,10 +287,10 @@ static void credit_people(struct strbuf *out,
const char *me;
if (kind == 'a') {
- label = "\n# By ";
+ label = "By";
me = git_author_info(IDENT_NO_DATE);
} else {
- label = "\n# Via ";
+ label = "Via";
me = git_committer_info(IDENT_NO_DATE);
}
@@ -300,7 +300,7 @@ static void credit_people(struct strbuf *out,
(me = skip_prefix(me, them->items->string)) != NULL &&
skip_prefix(me, " <")))
return;
- strbuf_addstr(out, label);
+ strbuf_addf(out, "\n%c %s ", comment_line_char, label);
add_people_count(out, them);
}