diff options
author | Jeff King <peff@peff.net> | 2009-09-09 10:59:37 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-09-11 21:41:15 -0700 |
commit | 0c3d3ac352427738e7c4393c0a959e0e698a0c7a (patch) | |
tree | 2ca6e0610347e5d4fb0bae0b6cff3cdca2326053 | |
parent | 25fc1786ab147daa9ffa43ebcbaf5c1cc6e50d4f (diff) | |
download | git-0c3d3ac352427738e7c4393c0a959e0e698a0c7a.tar.gz git-0c3d3ac352427738e7c4393c0a959e0e698a0c7a.tar.xz |
rebase: use plumbing to show dirty state
Commit 4cfbe06 introduced the use of "git diff" to show
dirty state in a format more familiar to users. However, it
should have used the plumbing "git diff-files" instead.
Not only is it good practice in general to use plumbing in
scripts, but in this case we really don't want the automatic
pager to kick in for an error message.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rwxr-xr-x | git-rebase.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/git-rebase.sh b/git-rebase.sh index 2315d95a9..6ec155cf0 100755 --- a/git-rebase.sh +++ b/git-rebase.sh @@ -387,7 +387,7 @@ fi # The tree must be really really clean. if ! git update-index --ignore-submodules --refresh > /dev/null; then echo >&2 "cannot rebase: you have unstaged changes" - git diff --name-status -r --ignore-submodules -- >&2 + git diff-files --name-status -r --ignore-submodules -- >&2 exit 1 fi diff=$(git diff-index --cached --name-status -r --ignore-submodules HEAD --) |