mirror of
https://github.com/nix-community/home-manager
synced 2024-12-25 03:09:47 +01:00
parent
6239ce20af
commit
caf3349f01
1 changed files with 7 additions and 1 deletions
|
@ -13,9 +13,15 @@ let
|
||||||
let
|
let
|
||||||
tweakVal = v:
|
tweakVal = v:
|
||||||
if isString v then "'${v}'"
|
if isString v then "'${v}'"
|
||||||
else if isList v then "[" + concatMapStringsSep "," tweakVal v + "]"
|
else if isList v then tweakList v
|
||||||
else if isBool v then (if v then "true" else "false")
|
else if isBool v then (if v then "true" else "false")
|
||||||
else toString v;
|
else toString v;
|
||||||
|
|
||||||
|
# Assume empty list is a list of strings, see #769
|
||||||
|
tweakList = v:
|
||||||
|
if v == [] then "@as []"
|
||||||
|
else "[" + concatMapStringsSep "," tweakVal v + "]";
|
||||||
|
|
||||||
in
|
in
|
||||||
"${key}=${tweakVal value}";
|
"${key}=${tweakVal value}";
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue