From: Junio C Hamano Date: Wed, 17 Aug 2005 01:08:19 +0000 (-0700) Subject: git-commit: pass explicit path to git-diff-files. X-Git-Tag: v0.99.5~16^2~7 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=22cff6a5abef29ce74da3e57ba3488d77686fec8;p=git.git git-commit: pass explicit path to git-diff-files. When running "git commit" with explicit path arguments, allow it to take directory name. This makes "git commit Documentation/" to commit everything that is changed under Documentation/ directory. Signed-off-by: Junio C Hamano --- diff --git a/git-commit-script b/git-commit-script index 790f07c08..f6cd75f02 100755 --- a/git-commit-script +++ b/git-commit-script @@ -88,9 +88,14 @@ esac case "$all" in t) git-diff-files --name-only -z | - xargs -0 git-update-cache -q -- || exit 1 ;; -esac -git-update-cache -q --refresh -- "$@" || exit 1 + xargs -0 git-update-cache -q -- + ;; +*) + git-diff-files --name-only -z "$@" | + xargs -0 git-update-cache -q -- + ;; +esac || exit 1 +git-update-cache -q --refresh || exit 1 case "$verify" in t)