shortlog: add usage-string for stdin-reading
authorMartin Ågren <martin.agren@gmail.com>
Sat, 10 Mar 2018 11:52:11 +0000 (12:52 +0100)
committerJunio C Hamano <gitster@pobox.com>
Tue, 13 Mar 2018 19:22:56 +0000 (12:22 -0700)
This has been missing since we learned to print usage, way back in
4e27fb06f (add commit count options to git-shortlog, 2006-10-06).

While at it, drop the [] around "<path>...". This matches `git log -h`
and Documentation/git-{short}log.txt. It formally makes it look like we
do not allow `git shortlog --`, but we gain readability and consistency.

Signed-off-by: Martin Ågren <martin.agren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/shortlog.c
index e29875b84389b25237e39e0112eafa8ac34599ee..dc4af03fca48fc718d71a15d0d51f2c35aee75a9 100644 (file)
@@ -11,7 +11,8 @@
 #include "parse-options.h"
 
 static char const * const shortlog_usage[] = {
-       N_("git shortlog [<options>] [<revision-range>] [[--] [<path>...]]"),
+       N_("git shortlog [<options>] [<revision-range>] [[--] <path>...]"),
+       N_("git log --pretty=short | git shortlog [<options>]"),
        NULL
 };