summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 403994e)
raw | patch | inline | side by side (parent: 403994e)
author | Tay Ray Chuan <rctay89@gmail.com> | |
Mon, 10 May 2010 17:17:51 +0000 (01:17 +0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 10 May 2010 19:02:14 +0000 (12:02 -0700) |
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin.h | patch | blob | history | |
builtin/fmt-merge-msg.c | patch | blob | history |
diff --git a/builtin.h b/builtin.h
index 464588b299a473e9e1ee58cbc61e2f981030e37d..322901f339a47486854d90048cbec198db8fce56 100644 (file)
--- a/builtin.h
+++ b/builtin.h
extern void prune_packed_objects(int);
extern int fmt_merge_msg(int merge_summary, struct strbuf *in,
struct strbuf *out);
+extern int fmt_merge_msg_shortlog(struct strbuf *in, struct strbuf *out);
extern int commit_tree(const char *msg, unsigned char *tree,
struct commit_list *parents, unsigned char *ret,
const char *author);
index d0160cb8223051648900ed47fa84d218690ee6a8..48548cf11badaae6b34bfc4140164dde0dc10123 100644 (file)
--- a/builtin/fmt-merge-msg.c
+++ b/builtin/fmt-merge-msg.c
strbuf_addf(out, " into %s\n", current_branch);
}
-static int do_fmt_merge_msg(int merge_summary, struct strbuf *in,
- struct strbuf *out) {
+static int do_fmt_merge_msg(int merge_title, int merge_summary,
+ struct strbuf *in, struct strbuf *out) {
int limit = 20, i = 0, pos = 0;
unsigned char head_sha1[20];
const char *current_branch;
if (!srcs.nr)
return 0;
- do_fmt_merge_msg_title(out, current_branch);
+ if (merge_title)
+ do_fmt_merge_msg_title(out, current_branch);
if (merge_summary) {
struct commit *head;
}
int fmt_merge_msg(int merge_summary, struct strbuf *in, struct strbuf *out) {
- return do_fmt_merge_msg(merge_summary, in, out);
+ return do_fmt_merge_msg(1, merge_summary, in, out);
+}
+
+int fmt_merge_msg_shortlog(struct strbuf *in, struct strbuf *out) {
+ return do_fmt_merge_msg(0, 1, in, out);
}
int cmd_fmt_merge_msg(int argc, const char **argv, const char *prefix)