diff options
author | Derrick Stolee <dstolee@microsoft.com> | 2020-01-31 20:16:10 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2020-01-31 13:05:29 -0800 |
commit | d585f0e7992ea7f025a5a91f46f2baa9e88f19f6 (patch) | |
tree | d311a04ddf853f4784a28e590c6eeb76c9dd91c5 /t/t5540-http-push-webdav.sh | |
parent | sparse-checkout: properly match escaped characters (diff) | |
download | tgif-d585f0e7992ea7f025a5a91f46f2baa9e88f19f6.tar.xz |
sparse-checkout: write escaped patterns in cone mode
If a user somehow creates a directory with an asterisk (*) or backslash
(\), then the "git sparse-checkout set" command will struggle to provide
the correct pattern in the sparse-checkout file. When not in cone mode,
the provided pattern is written directly into the sparse-checkout file.
However, in cone mode we expect a list of paths to directories and then
we convert those into patterns.
However, there is some care needed for the timing of these escapes. The
in-memory pattern list is used to update the working directory before
writing the patterns to disk. Thus, we need the command to have the
unescaped names in the hashsets for the cone comparisons, then escape
the patterns later.
Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5540-http-push-webdav.sh')
0 files changed, 0 insertions, 0 deletions