@matheusbsbs / matheus-bagliano / commits / 02646fe55d
Fork 0

Documentation/shortlog: scripted users should not rely on implicit HEAD

When passed no revision arguments, ‘git shortlog’ reads a log from stdin if and only if stdin is not a tty. So scripts that need to function identically when standard input is a terminal (as when run interactively) and not (as when run through a cron job) should either supply a log themselves or specify the desired revisions explicitly. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jonathan Nieder committed May 3, 2010 at 21:57 UTC 02646fe55dbbbdd8559f7ed2f38385ffb6b9571c
1 file changed +6 -1
Documentation/git-shortlog.txt
+6 -1
@@ -9,7 +9,7 @@ SYNOPSIS
9 --------
10 [verse]
11 git log --pretty=short | 'git shortlog' [-h] [-n] [-s] [-e] [-w]
12 -'git shortlog' [-n|--numbered] [-s|--summary] [-e|--email] [-w[<width>[,<indent1>[,<indent2>]]]] [<committish>...]
12 +'git shortlog' [-n|--numbered] [-s|--summary] [-e|--email] [-w[<width>[,<indent1>[,<indent2>]]]] <commit>...
13
14 DESCRIPTION
15 -----------
@@ -19,6 +19,11 @@ the first line of the commit message will be shown.
19
20 Additionally, "[PATCH]" will be stripped from the commit description.
21
22 +If no revisions are passed on the command line and either standard input
23 +is not a terminal or there is no current branch, 'git shortlog' will
24 +output a summary of the log read from standard input, without
25 +reference to the current repository.
26 +
27 OPTIONS
28 -------
29