Merge branch 'ah/doc-pretty-color-auto-prefix' into maint
authorJunio C Hamano <gitster@pobox.com>
Mon, 10 Jul 2017 20:59:05 +0000 (13:59 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 10 Jul 2017 20:59:05 +0000 (13:59 -0700)
Doc update.

* ah/doc-pretty-color-auto-prefix:
doc: clarify syntax for %C(auto,...) in pretty formats

1  2 
Documentation/pretty-formats.txt
index a48d267e26c1098e003ed6342b33c6e43d57a884,a4fa887683c3bfff11ef0708a69ba512cad5ef83..4d6dac5770bed76cada2f53334e239c70d15a073
@@@ -174,11 -174,12 +174,12 @@@ endif::git-rev-list[
  - '%Creset': reset color
  - '%C(...)': color specification, as described under Values in the
    "CONFIGURATION FILE" section of linkgit:git-config[1];
-   adding `auto,` at the beginning will emit color only when colors are
-   enabled for log output (by `color.diff`, `color.ui`, or `--color`, and
-   respecting the `auto` settings of the former if we are going to a
-   terminal). `auto` alone (i.e. `%C(auto)`) will turn on auto coloring
-   on the next placeholders until the color is switched again.
+   adding `auto,` at the beginning (e.g. `%C(auto,red)`) will emit
+   color only when colors are enabled for log output (by `color.diff`,
+   `color.ui`, or `--color`, and respecting the `auto` settings of the
+   former if we are going to a terminal). `auto` alone (i.e.
+   `%C(auto)`) will turn on auto coloring on the next placeholders
+   until the color is switched again.
  - '%m': left (`<`), right (`>`) or boundary (`-`) mark
  - '%n': newline
  - '%%': a raw '%'
    than given and there are spaces on its left, use those spaces
  - '%><(<N>)', '%><|(<N>)': similar to '% <(<N>)', '%<|(<N>)'
    respectively, but padding both sides (i.e. the text is centered)
 --%(trailers): display the trailers of the body as interpreted by
 +- %(trailers): display the trailers of the body as interpreted by
    linkgit:git-interpret-trailers[1]
  
  NOTE: Some placeholders may depend on other options given to the
@@@ -213,8 -214,8 +214,8 @@@ If you add a `+` (plus sign) after '%' 
  is inserted immediately before the expansion if and only if the
  placeholder expands to a non-empty string.
  
 -If you add a `-` (minus sign) after '%' of a placeholder, line-feeds that
 -immediately precede the expansion are deleted if and only if the
 +If you add a `-` (minus sign) after '%' of a placeholder, all consecutive
 +line-feeds immediately preceding the expansion are deleted if and only if the
  placeholder expands to an empty string.
  
  If you add a ` ` (space) after '%' of a placeholder, a space