summaryrefslogtreecommitdiff
path: root/t/t4002-diff-basic.sh
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2006-05-17 08:17:46 (GMT)
committerJunio C Hamano <junkio@cox.net>2006-05-17 08:52:48 (GMT)
commitfcc387db9bc453dc7e07a262873481af2ee9e5c8 (patch)
treea3853842dc72ee181a0f548aa2a9ba0105464fd5 /t/t4002-diff-basic.sh
parent63dffdf03da65ddf1a02c3215ad15ba109189d42 (diff)
downloadgit-fcc387db9bc453dc7e07a262873481af2ee9e5c8.zip
git-fcc387db9bc453dc7e07a262873481af2ee9e5c8.tar.gz
git-fcc387db9bc453dc7e07a262873481af2ee9e5c8.tar.bz2
read-tree -m -u: do not overwrite or remove untracked working tree files.
When a merge results in a creation of a path that did not exist in HEAD, and if you already have that path on the working tree, because the index has not been told about the working tree file, read-tree happily removes it. The issue was brought up by Santi BĂ©jar on the list. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 't/t4002-diff-basic.sh')
-rwxr-xr-xt/t4002-diff-basic.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t4002-diff-basic.sh b/t/t4002-diff-basic.sh
index 769274a..56eda63 100755
--- a/t/t4002-diff-basic.sh
+++ b/t/t4002-diff-basic.sh
@@ -191,7 +191,7 @@ test_expect_success \
'rm -fr Z [A-Z][A-Z] &&
git-read-tree $tree_A &&
git-checkout-index -f -a &&
- git-read-tree -m $tree_O || return 1
+ git-read-tree --reset $tree_O || return 1
git-update-index --refresh >/dev/null ;# this can exit non-zero
git-diff-files >.test-a &&
cmp_diff_files_output .test-a .test-recursive-OA'
@@ -201,7 +201,7 @@ test_expect_success \
'rm -fr Z [A-Z][A-Z] &&
git-read-tree $tree_B &&
git-checkout-index -f -a &&
- git-read-tree -m $tree_O || return 1
+ git-read-tree --reset $tree_O || return 1
git-update-index --refresh >/dev/null ;# this can exit non-zero
git-diff-files >.test-a &&
cmp_diff_files_output .test-a .test-recursive-OB'
@@ -211,7 +211,7 @@ test_expect_success \
'rm -fr Z [A-Z][A-Z] &&
git-read-tree $tree_B &&
git-checkout-index -f -a &&
- git-read-tree -m $tree_A || return 1
+ git-read-tree --reset $tree_A || return 1
git-update-index --refresh >/dev/null ;# this can exit non-zero
git-diff-files >.test-a &&
cmp_diff_files_output .test-a .test-recursive-AB'