git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
d6468ad8f38ad837d6aaf888201e296285661c99 blob 929 bytes (raw)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
 
#!/bin/sh
#
# Copyright (c) 2007 Junio C Hamano

test_description='git checkout to switch between branches with symlink<->dir'

. ./test-lib.sh

test_expect_success setup '

	mkdir frotz &&
	echo hello >frotz/filfre &&
	git add frotz/filfre &&
	test_tick &&
	git commit -m "main has file frotz/filfre" &&

	git branch side &&

	echo goodbye >nitfol &&
	git add nitfol &&
	test_tick &&
	git commit -m "main adds file nitfol" &&

	git checkout side &&

	git rm --cached frotz/filfre &&
	mv frotz xyzzy &&
	test_ln_s_add xyzzy frotz &&
	git add xyzzy/filfre &&
	test_tick &&
	git commit -m "side moves frotz/ to xyzzy/ and adds frotz->xyzzy/"

'

test_expect_success 'switch from symlink to dir' '

	git checkout main

'

test_expect_success 'Remove temporary directories & switch to main' '
	rm -fr frotz xyzzy nitfol &&
	git checkout -f main
'

test_expect_success 'switch from dir to symlink' '

	git checkout side

'

test_done
debug log:

solving d6468ad8f3 ...
found d6468ad8f3 in https://public-inbox.org/git/9b368b1ce1c5462b1a6fda6755837806bf4edfa8.1605221039.git.gitgitgadget@gmail.com/ ||
	https://public-inbox.org/git/0d4f1275f745f90a1ea007dfc82510f0040ab4a0.1605629548.git.gitgitgadget@gmail.com/
found fc9aad530e in https://80x24.org/mirrors/git.git
preparing index
index prepared:
100755 fc9aad530e9f9078e95d99da5c1d0849e489d4cf	t/t2007-checkout-symlink.sh

applying [1/2] https://public-inbox.org/git/9b368b1ce1c5462b1a6fda6755837806bf4edfa8.1605221039.git.gitgitgadget@gmail.com/
diff --git a/t/t2007-checkout-symlink.sh b/t/t2007-checkout-symlink.sh
index fc9aad530e..d6468ad8f3 100755

Checking patch t/t2007-checkout-symlink.sh...
Applied patch t/t2007-checkout-symlink.sh cleanly.

skipping https://public-inbox.org/git/0d4f1275f745f90a1ea007dfc82510f0040ab4a0.1605629548.git.gitgitgadget@gmail.com/ for d6468ad8f3
index at:
100755 d6468ad8f38ad837d6aaf888201e296285661c99	t/t2007-checkout-symlink.sh

Code repositories for project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).