helpers: fix previous commit, ynh_replace_string already messes with set +x/-x so hmpf

This commit is contained in:
Alexandre Aubin 2024-01-14 18:32:53 +01:00
parent 9819560518
commit c2af17667b

View file

@ -554,8 +554,6 @@ ynh_replace_vars() {
# Manage arguments with getopts
ynh_handle_getopts_args "$@"
set +o xtrace # set +x
# Replace specific YunoHost variables
if test -n "${path_url:-}"; then
# path_url_slash_less is path_url, or a blank value if path_url is only '/'
@ -586,6 +584,8 @@ ynh_replace_vars() {
# List other unique (__ __) variables in $file
local uniques_vars=($(grep -oP '__[A-Z0-9]+?[A-Z0-9_]*?[A-Z0-9]*?__' $file | sort --unique | sed "s@__\([^.]*\)__@\L\1@g"))
set +o xtrace # set +x
# Do the replacement
local delimit=@
for one_var in "${uniques_vars[@]}"; do