From 747d1e01e186129189c4b0b384397000c7791429 Mon Sep 17 00:00:00 2001 From: Kris Date: Thu, 19 Feb 2026 21:39:31 +0200 Subject: [PATCH] a --- modules/wafrn.nix | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/wafrn.nix b/modules/wafrn.nix index 29790a0..e11ec40 100644 --- a/modules/wafrn.nix +++ b/modules/wafrn.nix @@ -507,8 +507,8 @@ in ;; esac - key="${raw_line%%=*}" - value="${raw_line#*=}" + key="''${raw_line%%=*}" + value="''${raw_line#*=}" key="$(printf '%s' "$key" | tr -d '[:space:]')" if ! printf '%s' "$key" | grep -Eq '^[A-Za-z_][A-Za-z0-9_]*$'; then @@ -516,16 +516,16 @@ in continue fi - first_char="${value:0:1}" - last_char="${value: -1}" + first_char="''${value:0:1}" + last_char="''${value: -1}" if [ "$first_char" = '"' ] && [ "$last_char" = '"' ]; then - value="${value:1:${#value}-2}" + value="''${value:1:''${#value}-2}" elif [ "$first_char" = "'" ] && [ "$last_char" = "'" ]; then - value="${value:1:${#value}-2}" + value="''${value:1:''${#value}-2}" fi - value="${value//\\/\\\\}" - value="${value//\"/\\\"}" + value="''${value//\\/\\\\}" + value="''${value//\"/\\\"}" printf '%s="%s"\n' "$key" "$value" >> ${serviceEnvFile} done < "${cfg.secretsFile}" ''}