diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-01-05 23:41:57 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-01-05 23:41:57 -0800 |
commit | 946a5aee3e896aa12cb9d4d21079c6e299baad81 (patch) | |
tree | 86bc33d1262dfec0a36bbca5b0825298189bb710 /log-tree.c | |
parent | d2638e1561012e0f5b473ab43ef76c4ff0d12a9f (diff) | |
parent | 30825178fb72e3664bd1bda7c02c62e300e2e5ce (diff) | |
download | git-946a5aee3e896aa12cb9d4d21079c6e299baad81.tar.gz |
Merge branch 'jc/format-color-auto'
Introduce "log --format=%C(auto,blue)Foo%C(auto,reset)" that does
not color its output when writing to a non-terminal.
* jc/format-color-auto:
log --format: teach %C(auto,black) to respect color config
t6006: clean up whitespace
Diffstat (limited to 'log-tree.c')
-rw-r--r-- | log-tree.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/log-tree.c b/log-tree.c index 4f86defe32..8876c736d4 100644 --- a/log-tree.c +++ b/log-tree.c @@ -671,6 +671,7 @@ void show_log(struct rev_info *opt) ctx.preserve_subject = opt->preserve_subject; ctx.reflog_info = opt->reflog_info; ctx.fmt = opt->commit_format; + ctx.color = opt->diffopt.use_color; pretty_print_commit(&ctx, commit, &msgbuf); if (opt->add_signoff) |