* [PATCH] Be verbose when !initial commit
@ 2006-03-20 13:11 Yasushi SHOJI
0 siblings, 0 replies; only message in thread
From: Yasushi SHOJI @ 2006-03-20 13:11 UTC (permalink / raw
To: git
verbose option in git-commit.sh lead us to run git-diff-index, which
needs a commit-ish we are making diff against. When we are commiting
the fist set, we obviously don't have any commit-ish in the repo. So
we just skip the git-diff-index run.
It might be possible to produce diff against empty but do we need
that?
Signed-off-by: Yasushi SHOJI <yashi@atmark-techno.com>
---
git-commit.sh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
e071afdc1c6e9ce6bbee14aa0652e7bb7043550c
diff --git a/git-commit.sh b/git-commit.sh
index 330a434..1e7c09e 100755
--- a/git-commit.sh
+++ b/git-commit.sh
@@ -161,7 +161,7 @@ run_status () {
}
'
- if test -n "$verbose"
+ if test -n "$verbose" -a -z "$IS_INITIAL"
then
git-diff-index --cached -M -p --diff-filter=MDTCRA $REFERENCE
fi
--
1.2.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2006-03-20 13:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-20 13:11 [PATCH] Be verbose when !initial commit Yasushi SHOJI
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).