Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-08-18 02:17:03 +0400
committerJunio C Hamano <junkio@cox.net>2005-08-18 02:17:03 +0400
commit6a0049c07623a387bf7f7e7c90b71344c23decfa (patch)
tree9e7ea37f61dd57c5bf0a2d43a1cbb0d8b075d80d /git-commit-script
parentcfb0af1d50247e66ea1d46014650e60e9cfb87b9 (diff)
Fix git-commit without paths.
The earlier one to grab output from diff-files --name-only has a grave bug that when no paths are given it ended up doing the equivalent of "git-commit --all", which was not what I intended. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'git-commit-script')
-rwxr-xr-xgit-commit-script6
1 files changed, 4 insertions, 2 deletions
diff --git a/git-commit-script b/git-commit-script
index f6cd75f024..15d03913d5 100755
--- a/git-commit-script
+++ b/git-commit-script
@@ -85,11 +85,13 @@ tt*)
die "Only one of -c/-C/-F/-m can be used." ;;
esac
-case "$all" in
-t)
+case "$all,$#" in
+t,*)
git-diff-files --name-only -z |
xargs -0 git-update-cache -q --
;;
+,0)
+ ;;
*)
git-diff-files --name-only -z "$@" |
xargs -0 git-update-cache -q --