about summary refs log tree commit diff
path: root/third_party/git/t/t2022-checkout-paths.sh
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-09-21T10·03+0300
committerVincent Ambo <mail@tazj.in>2021-09-21T11·29+0300
commit43b1791ec601732ac31195df96781a848360a9ac (patch)
treedaae8d638343295d2f1f7da955e556ef4c958864 /third_party/git/t/t2022-checkout-paths.sh
parent2d8e7dc9d9c38127ec4ebd13aee8e8f586a43318 (diff)
chore(3p/git): Unvendor git and track patches instead r/2903
This was vendored a long time ago under the expectation that keeping
it in sync with cgit would be easier this way, but it has proven not
to be a big issue.

On the other hand, a vendored copy of git is an annoying maintenance
burden. It is much easier to rebase the single (dottime) patch that we
have.

This removes the vendored copy of git and instead passes the git
source code to cgit via `pkgs.srcOnly`, which includes the applied
patch so that cgit can continue rendering dottime.

Change-Id: If31f62dea7ce688fd1b9050204e9378019775f2b
Diffstat (limited to 'third_party/git/t/t2022-checkout-paths.sh')
-rwxr-xr-xthird_party/git/t/t2022-checkout-paths.sh92
1 files changed, 0 insertions, 92 deletions
diff --git a/third_party/git/t/t2022-checkout-paths.sh b/third_party/git/t/t2022-checkout-paths.sh
deleted file mode 100755
index 6844afafc0..0000000000
--- a/third_party/git/t/t2022-checkout-paths.sh
+++ /dev/null
@@ -1,92 +0,0 @@
-#!/bin/sh
-
-test_description='checkout $tree -- $paths'
-. ./test-lib.sh
-
-test_expect_success setup '
-	mkdir dir &&
-	>dir/master &&
-	echo common >dir/common &&
-	git add dir/master dir/common &&
-	test_tick && git commit -m "master has dir/master" &&
-	git checkout -b next &&
-	git mv dir/master dir/next0 &&
-	echo next >dir/next1 &&
-	git add dir &&
-	test_tick && git commit -m "next has dir/next but not dir/master"
-'
-
-test_expect_success 'checking out paths out of a tree does not clobber unrelated paths' '
-	git checkout next &&
-	git reset --hard &&
-	rm dir/next0 &&
-	cat dir/common >expect.common &&
-	echo modified >expect.next1 &&
-	cat expect.next1 >dir/next1 &&
-	echo untracked >expect.next2 &&
-	cat expect.next2 >dir/next2 &&
-
-	git checkout master dir &&
-
-	test_cmp expect.common dir/common &&
-	test_path_is_file dir/master &&
-	git diff --exit-code master dir/master &&
-
-	test_path_is_missing dir/next0 &&
-	test_cmp expect.next1 dir/next1 &&
-	test_path_is_file dir/next2 &&
-	test_must_fail git ls-files --error-unmatch dir/next2 &&
-	test_cmp expect.next2 dir/next2
-'
-
-test_expect_success 'do not touch unmerged entries matching $path but not in $tree' '
-	git checkout next &&
-	git reset --hard &&
-
-	cat dir/common >expect.common &&
-	EMPTY_SHA1=$(git hash-object -w --stdin </dev/null) &&
-	git rm dir/next0 &&
-	cat >expect.next0 <<-EOF &&
-	100644 $EMPTY_SHA1 1	dir/next0
-	100644 $EMPTY_SHA1 2	dir/next0
-	EOF
-	git update-index --index-info <expect.next0 &&
-
-	git checkout master dir &&
-
-	test_cmp expect.common dir/common &&
-	test_path_is_file dir/master &&
-	git diff --exit-code master dir/master &&
-	git ls-files -s dir/next0 >actual.next0 &&
-	test_cmp expect.next0 actual.next0
-'
-
-test_expect_success 'do not touch files that are already up-to-date' '
-	git reset --hard &&
-	echo one >file1 &&
-	echo two >file2 &&
-	git add file1 file2 &&
-	git commit -m base &&
-	echo modified >file1 &&
-	test-tool chmtime =1000000000 file2 &&
-	git update-index -q --refresh &&
-	git checkout HEAD -- file1 file2 &&
-	echo one >expect &&
-	test_cmp expect file1 &&
-	echo "1000000000" >expect &&
-	test-tool chmtime --get file2 >actual &&
-	test_cmp expect actual
-'
-
-test_expect_success 'checkout HEAD adds deleted intent-to-add file back to index' '
-	echo "nonempty" >nonempty &&
-	>empty &&
-	git add nonempty empty &&
-	git commit -m "create files to be deleted" &&
-	git rm --cached nonempty empty &&
-	git add -N nonempty empty &&
-	git checkout HEAD nonempty empty &&
-	git diff --cached --exit-code
-'
-
-test_done