summaryrefslogtreecommitdiff
path: root/pretty.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2014-09-29 12:36:08 -0700
committerJunio C Hamano <gitster@pobox.com>2014-09-29 12:36:09 -0700
commitb8e533f12acec63242c5405286fbbcfa66eecfdd (patch)
tree32ededef297ace728b1c59a5425b8b383eae75a8 /pretty.c
parenta9583afc1df1df10d60d2b81fd4b0976bc67ca4e (diff)
parent9271095cc5571e306d709ebf8eb7f0a388254d9d (diff)
downloadgit-b8e533f12acec63242c5405286fbbcfa66eecfdd.tar.gz
Merge branch 'hj/pretty-naked-decoration'
The pretty-format specifier "%d", which expanded to " (tagname)" for a tagged commit, gained a cousin "%D" that just gives the "tagname" without frills. * hj/pretty-naked-decoration: pretty: add %D format specifier
Diffstat (limited to 'pretty.c')
-rw-r--r--pretty.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/pretty.c b/pretty.c
index 31f2edef11..5fd9de6ce1 100644
--- a/pretty.c
+++ b/pretty.c
@@ -1179,6 +1179,10 @@ static size_t format_commit_one(struct strbuf *sb, /* in UTF-8 */
load_ref_decorations(DECORATE_SHORT_REFS);
format_decorations(sb, commit, c->auto_color);
return 1;
+ case 'D':
+ load_ref_decorations(DECORATE_SHORT_REFS);
+ format_decorations_extended(sb, commit, c->auto_color, "", ", ", "");
+ return 1;
case 'g': /* reflog info */
switch(placeholder[1]) {
case 'd': /* reflog selector */