diff options
author | Junio C Hamano <gitster@pobox.com> | 2016-12-21 14:55:02 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-12-21 14:55:02 -0800 |
commit | fe050334074c5132d01e1df2c1b9a82c9b8d394c (patch) | |
tree | a5d4136c6aa15eae56ff19c3fffb94acad289757 /t/t5615-alternate-env.sh | |
parent | Merge branch 'vs/submodule-clone-nested-submodules-alternates' (diff) | |
parent | t5615-alternate-env: double-quotes in file names do not work on Windows (diff) | |
download | tgif-fe050334074c5132d01e1df2c1b9a82c9b8d394c.tar.xz |
Merge branch 'jk/quote-env-path-list-component'
A recent update to receive-pack to make it easier to drop garbage
objects made it clear that GIT_ALTERNATE_OBJECT_DIRECTORIES cannot
have a pathname with a colon in it (no surprise!), and this in turn
made it impossible to push into a repository at such a path. This
has been fixed by introducing a quoting mechanism used when
appending such a path to the colon-separated list.
* jk/quote-env-path-list-component:
t5615-alternate-env: double-quotes in file names do not work on Windows
t5547-push-quarantine: run the path separator test on Windows, too
tmp-objdir: quote paths we add to alternates
alternates: accept double-quoted paths
Diffstat (limited to 't/t5615-alternate-env.sh')
-rwxr-xr-x | t/t5615-alternate-env.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/t/t5615-alternate-env.sh b/t/t5615-alternate-env.sh index eec4137ca5..26ebb0375d 100755 --- a/t/t5615-alternate-env.sh +++ b/t/t5615-alternate-env.sh @@ -68,4 +68,22 @@ test_expect_success 'access alternate via relative path (subdir)' ' EOF ' +# set variables outside test to avoid quote insanity; the \057 is '/', +# which doesn't need quoting, but just confirms that de-quoting +# is working. +quoted='"one.git\057objects"' +unquoted='two.git/objects' +test_expect_success 'mix of quoted and unquoted alternates' ' + check_obj "$quoted:$unquoted" <<-EOF + $one blob + $two blob +' + +test_expect_success !MINGW 'broken quoting falls back to interpreting raw' ' + mv one.git \"one.git && + check_obj \"one.git/objects <<-EOF + $one blob + EOF +' + test_done |