@matheusbsbs / matheus-bagliano / commits / ab18b2c0df
Fork 0

log/pretty-options: Document --[no-]notes and deprecate old notes options

Document the behavior or the new --notes, --notes=<ref> and --no-notes options, and list --show-notes[=<ref>] and --[no-]standard-notes options as deprecated. Signed-off-by: Johan Herland <johan@herland.net> Acked-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Johan Herland committed Mar 30, 2011 at 02:57 UTC ab18b2c0df93b518ff9591d69e5e607fee718814
2 files changed +27 -12
Documentation/git-log.txt
+2 -2
@@ -178,9 +178,9 @@ May be an unabbreviated ref name or a glob and may be specified
178 multiple times. A warning will be issued for refs that do not exist,
179 but a glob that does not match any refs is silently ignored.
180 +
181 -This setting can be disabled by the `--no-standard-notes` option,
181 +This setting can be disabled by the `--no-notes` option,
182 overridden by the 'GIT_NOTES_DISPLAY_REF' environment variable,
183 -and supplemented by the `--show-notes` option.
183 +and overridden by the `--notes=<ref>` option.
184
185 GIT
186 ---
Documentation/pretty-options.txt
+25 -10
@@ -30,19 +30,34 @@ people using 80-column terminals.
30 preferred by the user. For non plumbing commands this
31 defaults to UTF-8.
32
33 ---no-notes::
34 ---show-notes[=<ref>]::
33 +--notes[=<ref>]::
34 Show the notes (see linkgit:git-notes[1]) that annotate the
35 commit, when showing the commit log message. This is the default
36 for `git log`, `git show` and `git whatchanged` commands when
38 - there is no `--pretty`, `--format` nor `--oneline` option is
39 - given on the command line.
37 + there is no `--pretty`, `--format` nor `--oneline` option given
38 + on the command line.
39 ++
40 +By default, the notes shown are from the notes refs listed in the
41 +'core.notesRef' and 'notes.displayRef' variables (or corresponding
42 +environment overrides). See linkgit:git-config[1] for more details.
43 ++
44 +With an optional '<ref>' argument, show this notes ref instead of the
45 +default notes ref(s). The ref is taken to be in `refs/notes/` if it
46 +is not qualified.
47 +
41 -With an optional argument, add this ref to the list of notes. The ref
42 -is taken to be in `refs/notes/` if it is not qualified.
48 +Multiple --notes options can be combined to control which notes are
49 +being displayed. Examples: "--notes=foo" will show only notes from
50 +"refs/notes/foo"; "--notes=foo --notes" will show both notes from
51 +"refs/notes/foo" and from the default notes ref(s).
52
53 +--no-notes::
54 + Do not show notes. This negates the above `--notes` option, by
55 + resetting the list of notes refs from which notes are shown.
56 + Options are parsed in the order given on the command line, so e.g.
57 + "--notes --notes=foo --no-notes --notes=bar" will only show notes
58 + from "refs/notes/bar".
59 +
60 +--show-notes[=<ref>]::
61 --[no-]standard-notes::
45 - Enable or disable populating the notes ref list from the
46 - 'core.notesRef' and 'notes.displayRef' variables (or
47 - corresponding environment overrides). Enabled by default.
48 - See linkgit:git-config[1].
62 + These options are deprecated. Use the above --notes/--no-notes
63 + options instead.