From 02646fe55dbbbdd8559f7ed2f38385ffb6b9571c Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Mon, 3 May 2010 21:57:10 -0500 Subject: Documentation/shortlog: scripted users should not rely on implicit HEAD MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Signed-off-by: Junio C Hamano --- Documentation/git-shortlog.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Documentation') diff --git a/Documentation/git-shortlog.txt b/Documentation/git-shortlog.txt index dfd4d0c223..f11ea90237 100644 --- a/Documentation/git-shortlog.txt +++ b/Documentation/git-shortlog.txt @@ -9,7 +9,7 @@ SYNOPSIS -------- [verse] git log --pretty=short | 'git shortlog' [-h] [-n] [-s] [-e] [-w] -'git shortlog' [-n|--numbered] [-s|--summary] [-e|--email] [-w[[,[,]]]] [...] +'git shortlog' [-n|--numbered] [-s|--summary] [-e|--email] [-w[[,[,]]]] ... DESCRIPTION ----------- @@ -19,6 +19,11 @@ the first line of the commit message will be shown. Additionally, "[PATCH]" will be stripped from the commit description. +If no revisions are passed on the command line and either standard input +is not a terminal or there is no current branch, 'git shortlog' will +output a summary of the log read from standard input, without +reference to the current repository. + OPTIONS ------- -- cgit v1.2.3 From 600372497c668045a365b9eab76987ee19405f7a Mon Sep 17 00:00:00 2001 From: Jonathan Nieder Date: Mon, 3 May 2010 21:59:55 -0500 Subject: shortlog: Document and test --format option Do not document the --pretty synonym, since it takes too long to explain the name to people. Signed-off-by: Jonathan Nieder Signed-off-by: Junio C Hamano --- Documentation/git-shortlog.txt | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'Documentation') diff --git a/Documentation/git-shortlog.txt b/Documentation/git-shortlog.txt index f11ea90237..bc1ac77495 100644 --- a/Documentation/git-shortlog.txt +++ b/Documentation/git-shortlog.txt @@ -44,6 +44,14 @@ OPTIONS --email:: Show the email address of each author. +--format[='']:: + Instead of the commit subject, use some other information to + describe each commit. '' can be any string accepted + by the `--format` option of 'git log', such as '{asterisk} [%h] %s'. + (See the "PRETTY FORMATS" section of linkgit:git-log[1].) + + Each pretty-printed commit will be rewrapped before it is shown. + -w[[,[,]]]:: Linewrap the output by wrapping each line at `width`. The first line of each entry is indented by `indent1` spaces, and the second -- cgit v1.2.3