From 7f1838372a810251a7553bf90651c49e220def12 Mon Sep 17 00:00:00 2001 From: Dominique Liberda Date: Wed, 18 Jan 2023 06:24:10 +0100 Subject: [PATCH] * fix regression due to sed's imporper regexp handling --- src/template.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/template.sh b/src/template.sh index 75b081a..413c409 100755 --- a/src/template.sh +++ b/src/template.sh @@ -41,7 +41,7 @@ function render() { local _key="\\?${key/?/}" local subtemplate=$(mktemp) - echo 's'$'\02''\{\{start '"$_key"'\}\}((.*)\{\{else '"$_key"'\}\}.*\{\{end '"$_key"'\}\}|(.*)\{\{end '"$_key"'\}\})'$'\02''\2'$'\02'';' >> "$subtemplate" + echo 's'$'\02''\{\{start '"$_key"'\}\}((.*)\{\{else '"$_key"'\}\}.*\{\{end '"$_key"'\}\}|(.*)\{\{end '"$_key"'\}\})'$'\02''\2\3'$'\02'';' >> "$subtemplate" cat <<< $(cat "$subtemplate" "$tmp") > "$tmp" # call that cat abuse elif [[ "${ref[$key]}" != "" ]]; then