summaryrefslogtreecommitdiff
path: root/t/t4009-diff-rename-4.sh
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-06-19 20:14:05 (GMT)
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-20 03:13:18 (GMT)
commit4727f640036fbdad414bdcbe31d08f6a8fd70923 (patch)
tree5458d4661aed71ae5864f663f636cf9707e43e9e /t/t4009-diff-rename-4.sh
parent170241b7d1437e082c13a6f6b812eb827a7d48e0 (diff)
downloadgit-4727f640036fbdad414bdcbe31d08f6a8fd70923.zip
git-4727f640036fbdad414bdcbe31d08f6a8fd70923.tar.gz
git-4727f640036fbdad414bdcbe31d08f6a8fd70923.tar.bz2
[PATCH] Make -C less eager.
Like diff-tree, this patch makes -C option for diff-* brothers to use only pre-image of modified files as rename/copy detection by default. Give --find-copies-harder to use unmodified files to find copies from as well. This also fixes "diff-files -C" problem earlier noticed by Linus. It was feeding the null sha1 even when the file in the work tree was known to match what is in the index file. This resulted in diff-files showing everything in the project. Signed-off-by: Junio C Hamano <junkio@cox.net> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 't/t4009-diff-rename-4.sh')
-rw-r--r--t/t4009-diff-rename-4.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t4009-diff-rename-4.sh b/t/t4009-diff-rename-4.sh
index 318915f..6229a5b 100644
--- a/t/t4009-diff-rename-4.sh
+++ b/t/t4009-diff-rename-4.sh
@@ -143,7 +143,7 @@ test_expect_success \
'cat ../../COPYING >COPYING &&
git-update-cache --add --remove COPYING COPYING.1'
-git-diff-cache -z -C $tree >current
+git-diff-cache -z -C --find-copies-harder $tree >current
cat >expected <<\EOF
:100644 100644 6ff87c4664981e4397625791c8ea3bbb5f2279a3 0603b3238a076dc6c8022aedc6648fa523a17178 C1234
COPYING