aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2022-07-27 13:19:51 -0700
committerJunio C Hamano <gitster@pobox.com>2022-07-27 13:19:51 -0700
commit2d39f66a52baad0f511e47b3e5be611bc4c60e7e (patch)
treeb856744090183479d66d13cd47dd8c52c5772cb4
parentMerge branch 'tb/pack-objects-remove-pahole-comment' into maint (diff)
parentt5510: replace 'origin' with URL more carefully (diff)
downloadgit-2d39f66a52baad0f511e47b3e5be611bc4c60e7e.tar.gz
git-2d39f66a52baad0f511e47b3e5be611bc4c60e7e.zip
Merge branch 'ds/t5510-brokequote' into maint
Test fix. source: <484a330e-0902-6e1b-8189-63c72dcea494@github.com> * ds/t5510-brokequote: t5510: replace 'origin' with URL more carefully
-rwxr-xr-xt/t5510-fetch.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index 4620f0ca7f..b45879a760 100755
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
@@ -853,7 +853,11 @@ test_configured_prune_type () {
then
new_cmdline=$cmdline_setup
else
- new_cmdline=$(printf "%s" "$cmdline" | perl -pe 's[origin(?!/)]["'"$remote_url"'"]g')
+ new_cmdline=$(perl -e '
+ my ($cmdline, $url) = @ARGV;
+ $cmdline =~ s[origin(?!/)][quotemeta($url)]ge;
+ print $cmdline;
+ ' -- "$cmdline" "$remote_url")
fi
if test "$fetch_prune_tags" = 'true' ||