]> git.ipfire.org Git - thirdparty/git.git/commitdiff
doc/log: correct default for --decorate
authorĐoàn Trần Công Danh <congdanhqx@gmail.com>
Tue, 8 Jun 2021 01:58:40 +0000 (08:58 +0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 8 Jun 2021 04:34:48 +0000 (13:34 +0900)
There're two different default options for log --decorate:
* Should `--decorate` be given without any arguments, it's default to
  `short`
* Should neither `--decorate` nor `--no-decorate` be given, it's default
  to the `log.decorate` or `auto`.

We documented the former, but not the latter.

Let's document them, too.

Reported-by: Andy AO <zen96285@gmail.com>
Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-log.txt

index 1bbf865a1b2d4f3157395d5f82a6bb47f4029b93..0498e7bacbe8ccf2b097e6c53464743c81f64eca 100644 (file)
@@ -39,7 +39,9 @@ OPTIONS
        full ref name (including prefix) will be printed. If 'auto' is
        specified, then if the output is going to a terminal, the ref names
        are shown as if 'short' were given, otherwise no ref names are
-       shown. The default option is 'short'.
+       shown. The option `--decorate` is short-hand for `--decorate=short`.
+       Default to configuration value of `log.decorate` if configured,
+       otherwise, `auto`.
 
 --decorate-refs=<pattern>::
 --decorate-refs-exclude=<pattern>::