From 4dc2b3b842c349ea9cc87bdab552cca2789257bf Mon Sep 17 00:00:00 2001 From: tschettervictor <85497460+tschettervictor@users.noreply.github.com> Date: Mon, 10 Feb 2025 12:07:12 -0700 Subject: [PATCH] template: Fix default value with spaces #692 @michael-o This essentially just makes sure there are not multiple quotes following each other inside the ARG value. --- usr/local/share/bastille/template.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr/local/share/bastille/template.sh b/usr/local/share/bastille/template.sh index 60a63480..a318e3f3 100644 --- a/usr/local/share/bastille/template.sh +++ b/usr/local/share/bastille/template.sh @@ -54,7 +54,7 @@ get_arg_name() { parse_arg_value() { # Parses the value after = and then escapes back/forward slashes and single quotes in it. -- cwells - echo "${1}" | sed -E 's/[^=]+=?//' | sed -e 's/\\/\\\\/g' -e 's/\//\\\//g' -e 's/'\''/'\''\\'\'\''/g' -e 's/&/\\&/g' + echo "${1}" | sed -E 's/[^=]+=?//' | sed -e 's/\\/\\\\/g' -e 's/\//\\\//g' -e 's/'\''/'\''\\'\'\''/g' -e 's/&/\\&/g' -e 's/""/"/g' } get_arg_value() {