From: Jeff King Date: Thu, 2 Feb 2017 12:42:44 +0000 (+0100) Subject: document behavior of empty color name X-Git-Tag: v2.12.0-rc0~10^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=512aba261a8951a470147b493c720f205638ba14;p=git document behavior of empty color name Commit 55cccf4bb (color_parse_mem: allow empty color spec, 2017-02-01) clearly defined the behavior of an empty color config variable. Let's document that, and give a hint about why it might be useful. It's important not to say that it makes the item uncolored, because it doesn't. It just sets no attributes, which means that any previous attributes continue to take effect. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff --git a/Documentation/config.txt b/Documentation/config.txt index 33a007b52e..49b264566c 100644 --- a/Documentation/config.txt +++ b/Documentation/config.txt @@ -170,6 +170,9 @@ The position of any attributes with respect to the colors be turned off by prefixing them with `no` or `no-` (e.g., `noreverse`, `no-ul`, etc). + +An empty color string produces no color effect at all. This can be used +to avoid coloring specific elements without disabling color entirely. ++ For git's pre-defined color slots, the attributes are meant to be reset at the beginning of each item in the colored output. So setting `color.decorate.branch` to `black` will paint that branch name in a