summaryrefslogtreecommitdiff
path: root/t/t4200-rerere.sh
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2008-07-12 14:56:19 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-07-13 08:03:10 (GMT)
commit0af0ac7ebbbd2afbc4399d5658e193460b4caaa3 (patch)
tree1d268eea677a25ac3eb8a7192f4871653ebfcbc7 /t/t4200-rerere.sh
parent99d698f1e703754422f1dd780487ddbff3726dc3 (diff)
downloadgit-0af0ac7ebbbd2afbc4399d5658e193460b4caaa3.zip
git-0af0ac7ebbbd2afbc4399d5658e193460b4caaa3.tar.gz
git-0af0ac7ebbbd2afbc4399d5658e193460b4caaa3.tar.bz2
Move MERGE_RR from .git/rr-cache/ into .git/
If you want to reuse the rerere cache in another repository, and set a symbolic link to it, you do not want to have the two repositories interfer with each other by accessing the _same_ MERGE_RR. For example, if you use contrib/git-new-workdir to set up a second working directory, and you have a conflict in one working directory, but commit in the other working directory first, the wrong "resolution" will be recorded. The easy solution is to move MERGE_RR out of the rr-cache/ directory, which also corresponds with the notion that rr-cache/ contains cached resolutions, not some intermediate temporary states. Noticed by Kalle Olavi Niemitalo. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4200-rerere.sh')
-rwxr-xr-xt/t4200-rerere.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t4200-rerere.sh b/t/t4200-rerere.sh
index cf10557..b5a4202 100755
--- a/t/t4200-rerere.sh
+++ b/t/t4200-rerere.sh
@@ -57,7 +57,7 @@ test_expect_success 'conflicting merge' '
! git merge first
'
-sha1=$(sed -e 's/ .*//' .git/rr-cache/MERGE_RR)
+sha1=$(sed -e 's/ .*//' .git/MERGE_RR)
rr=.git/rr-cache/$sha1
test_expect_success 'recorded preimage' "grep ^=======$ $rr/preimage"
@@ -143,7 +143,7 @@ test_expect_success 'rerere kicked in' "! grep ^=======$ a1"
test_expect_success 'rerere prefers first change' 'test_cmp a1 expect'
rm $rr/postimage
-echo "$sha1 a1" | perl -pe 'y/\012/\000/' > .git/rr-cache/MERGE_RR
+echo "$sha1 a1" | perl -pe 'y/\012/\000/' > .git/MERGE_RR
test_expect_success 'rerere clear' 'git rerere clear'
@@ -190,7 +190,7 @@ test_expect_success 'file2 added differently in two branches' '
git add file2 &&
git commit -m version2 &&
! git merge fourth &&
- sha1=$(sed -e "s/ .*//" .git/rr-cache/MERGE_RR) &&
+ sha1=$(sed -e "s/ .*//" .git/MERGE_RR) &&
rr=.git/rr-cache/$sha1 &&
echo Cello > file2 &&
git add file2 &&