diff options
author | Vincent Ambo <mail@tazj.in> | 2021-09-21T10·03+0300 |
---|---|---|
committer | Vincent Ambo <mail@tazj.in> | 2021-09-21T11·29+0300 |
commit | 43b1791ec601732ac31195df96781a848360a9ac (patch) | |
tree | daae8d638343295d2f1f7da955e556ef4c958864 /third_party/git/t/t5522-pull-symlink.sh | |
parent | 2d8e7dc9d9c38127ec4ebd13aee8e8f586a43318 (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/t5522-pull-symlink.sh')
-rwxr-xr-x | third_party/git/t/t5522-pull-symlink.sh | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/third_party/git/t/t5522-pull-symlink.sh b/third_party/git/t/t5522-pull-symlink.sh deleted file mode 100755 index bcff460d0a2b..000000000000 --- a/third_party/git/t/t5522-pull-symlink.sh +++ /dev/null @@ -1,84 +0,0 @@ -#!/bin/sh - -test_description='pulling from symlinked subdir' - -. ./test-lib.sh - -# The scenario we are building: -# -# trash\ directory/ -# clone-repo/ -# subdir/ -# bar -# subdir-link -> clone-repo/subdir/ -# -# The working directory is subdir-link. - -test_expect_success SYMLINKS setup ' - mkdir subdir && - echo file >subdir/file && - git add subdir/file && - git commit -q -m file && - git clone -q . clone-repo && - ln -s clone-repo/subdir/ subdir-link && - ( - cd clone-repo && - git config receive.denyCurrentBranch warn - ) && - git config receive.denyCurrentBranch warn -' - -# Demonstrate that things work if we just avoid the symlink -# -test_expect_success SYMLINKS 'pulling from real subdir' ' - ( - echo real >subdir/file && - git commit -m real subdir/file && - cd clone-repo/subdir/ && - git pull && - test real = $(cat file) - ) -' - -# From subdir-link, pulling should work as it does from -# clone-repo/subdir/. -# -# Instead, the error pull gave was: -# -# fatal: 'origin': unable to chdir or not a git archive -# fatal: The remote end hung up unexpectedly -# -# because git would find the .git/config for the "trash directory" -# repo, not for the clone-repo repo. The "trash directory" repo -# had no entry for origin. Git found the wrong .git because -# git rev-parse --show-cdup printed a path relative to -# clone-repo/subdir/, not subdir-link/. Git rev-parse --show-cdup -# used the correct .git, but when the git pull shell script did -# "cd $(git rev-parse --show-cdup)", it ended up in the wrong -# directory. A POSIX shell's "cd" works a little differently -# than chdir() in C; "cd -P" is much closer to chdir(). -# -test_expect_success SYMLINKS 'pulling from symlinked subdir' ' - ( - echo link >subdir/file && - git commit -m link subdir/file && - cd subdir-link/ && - git pull && - test link = $(cat file) - ) -' - -# Prove that the remote end really is a repo, and other commands -# work fine in this context. It's just that "git pull" breaks. -# -test_expect_success SYMLINKS 'pushing from symlinked subdir' ' - ( - cd subdir-link/ && - echo push >file && - git commit -m push ./file && - git push - ) && - test push = $(git show HEAD:subdir/file) -' - -test_done |