From: Junio C Hamano Date: Mon, 17 Oct 2016 20:25:23 +0000 (-0700) Subject: Merge branch 'rs/pretty-format-color-doc-fix' X-Git-Tag: v2.11.0-rc0~54 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/c4e0d011f9987b95725cbbd146a5141b83857a40?ds=inline;hp=-c Merge branch 'rs/pretty-format-color-doc-fix' * rs/pretty-format-color-doc-fix: pretty: fix document link for color specification --- c4e0d011f9987b95725cbbd146a5141b83857a40 diff --combined Documentation/pretty-formats.txt index a942d57f73,867b159e8f..69c289dd0c --- a/Documentation/pretty-formats.txt +++ b/Documentation/pretty-formats.txt @@@ -147,14 -147,8 +147,14 @@@ endif::git-rev-list[ "U" for a good signature with unknown validity and "N" for no signature - '%GS': show the name of the signer for a signed commit - '%GK': show the key used to sign a signed commit -- '%gD': reflog selector, e.g., `refs/stash@{1}` -- '%gd': shortened reflog selector, e.g., `stash@{1}` +- '%gD': reflog selector, e.g., `refs/stash@{1}` or + `refs/stash@{2 minutes ago`}; the format follows the rules described + for the `-g` option. The portion before the `@` is the refname as + given on the command line (so `git log -g refs/heads/master` would + yield `refs/heads/master@{0}`). +- '%gd': shortened reflog selector; same as `%gD`, but the refname + portion is shortened for human readability (so `refs/heads/master` + becomes just `master`). - '%gn': reflog identity name - '%gN': reflog identity name (respecting .mailmap, see linkgit:git-shortlog[1] or linkgit:git-blame[1]) @@@ -166,13 -160,14 +166,14 @@@ - '%Cgreen': switch color to green - '%Cblue': switch color to blue - '%Creset': reset color - - '%C(...)': color specification, as described in color.branch.* config option; + - '%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. -- '%m': left, right or boundary mark +- '%m': left (`<`), right (`>`) or boundary (`-`) mark - '%n': newline - '%%': a raw '%' - '%x00': print a byte from a hex code