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>
This commit is contained in:
@ -85,11 +85,13 @@ tt*)
|
|||||||
die "Only one of -c/-C/-F/-m can be used." ;;
|
die "Only one of -c/-C/-F/-m can be used." ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
case "$all" in
|
case "$all,$#" in
|
||||||
t)
|
t,*)
|
||||||
git-diff-files --name-only -z |
|
git-diff-files --name-only -z |
|
||||||
xargs -0 git-update-cache -q --
|
xargs -0 git-update-cache -q --
|
||||||
;;
|
;;
|
||||||
|
,0)
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
git-diff-files --name-only -z "$@" |
|
git-diff-files --name-only -z "$@" |
|
||||||
xargs -0 git-update-cache -q --
|
xargs -0 git-update-cache -q --
|
||||||
|
Reference in New Issue
Block a user