> Stefan Beller <stefanbel...@googlemail.com> writes: > >> However I sometimes also get: >> sb@sb:~/OSS/git$ git show --format="%ad" 0da7a53 >> Fri Jul 12 10:49:34 2013 -0700 >> >> diff --git a/Documentation/RelNotes/1.8.4.txt >> b/Documentation/RelNotes/1.8.4.txt >> index 0e50df8..4250e5a 100644 >> --- a/Documentation/RelNotes/1.8.4.txt >> +++ b/Documentation/RelNotes/1.8.4.txt > > "git show" will show the diff by default. For merge commits, it shows > the --cc diff which is often empty, hence the behavior you see. > > You want to use "git show -s", which suppresses the patch output.
... and this "git show -s" is extraordinarily hard to discover, as it is only documented in "git log --help". Google has been my friend here, but we should really improve that. This patch series does essentially two things: * Add a --no-patch synonym for -s. I'm actually wondering why the option wasn't called this way from the beginning. * Reorganize the doc so that "git show" actually mentions it. While we're there, there's a reformatting patch, and one to make "git log --no-patch --patch" actually show the patch. (60aa9cf8f3, Documentation: document show -s, Tue Nov 9 11:12:48 2010 actually acknowledged that the documentation wasn't complete and that something else was needed, this should be it) Matthieu Moy (5): diff: allow --no-patch as synonym for -s diff: allow --patch to override -s/--no-patch Documentation/git-show.txt: include common diff options, like git-log.txt Documentation: move description of -s, --no-patch to diff-options.txt Documentation/git-log.txt: capitalize section names Documentation/diff-options.txt | 5 +++++ Documentation/git-log.txt | 8 ++++---- Documentation/git-show.txt | 9 +++++++++ Documentation/rev-list-options.txt | 3 --- diff.c | 7 ++++--- 5 files changed, 22 insertions(+), 10 deletions(-) -- 1.8.3.1.495.g13f33cf.dirty -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html