mirror of
https://github.com/foo-dogsquared/nix-module-wrapper-manager-fds.git
synced 2025-01-31 04:58:17 +00:00
wrapper-manager-fds/modules: allow envvar values to be non-escaped
This commit is contained in:
parent
dd389a65ec
commit
296e8ea59b
@ -31,6 +31,10 @@ let
|
||||
'';
|
||||
example = "HELLO THERE";
|
||||
};
|
||||
|
||||
isEscaped = lib.mkEnableOption "escaping of the value" // {
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
in
|
||||
@ -143,7 +147,7 @@ let
|
||||
(n: v:
|
||||
if v.action == "unset"
|
||||
then "--${v.action} ${lib.escapeShellArg n}"
|
||||
else "--${v.action} ${lib.escapeShellArg n} ${lib.escapeShellArg v.value}")
|
||||
else "--${v.action} ${lib.escapeShellArg n} ${if v.isEscaped then lib.escapeShellArg v.value else v.value}")
|
||||
config.env)
|
||||
++ (builtins.map (v: "--add-flags ${lib.escapeShellArg v}") config.prependArgs)
|
||||
++ (builtins.map (v: "--append-flags ${lib.escapeShellArg v}") config.appendArgs)
|
||||
|
Loading…
Reference in New Issue
Block a user