summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 25fc178)
raw | patch | inline | side by side (parent: 25fc178)
author | Jeff King <peff@peff.net> | |
Wed, 9 Sep 2009 14:59:37 +0000 (10:59 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sat, 12 Sep 2009 04:41:15 +0000 (21:41 -0700) |
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>
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>
git-rebase.sh | patch | blob | history |
diff --git a/git-rebase.sh b/git-rebase.sh
index 2315d95a9fb28e15190461a94a43e28e57fbe6c3..6ec155cf03c98f2e075f298039037d0e099311b1 100755 (executable)
--- a/git-rebase.sh
+++ b/git-rebase.sh
# 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 --)