nixos/shells-environment: allow int and float in environment variables

This commit is contained in:
Sandro Jäckel 2023-12-26 01:55:00 +01:00
parent 418cc44106
commit c5371710de
No known key found for this signature in database
GPG Key ID: 3AF5A43A3EECC2E5
1 changed files with 2 additions and 2 deletions

View File

@ -42,8 +42,8 @@ in
strings. The latter is concatenated, interspersed with colon
characters.
'';
type = with types; attrsOf (oneOf [ (listOf str) str path ]);
apply = mapAttrs (n: v: if isList v then concatStringsSep ":" v else "${v}");
type = with types; attrsOf (oneOf [ (listOf (oneOf [ float int str ])) float int str path ]);
apply = mapAttrs (n: v: if isList v then concatMapStringsSep ":" toString v else toString v);
};
environment.profiles = mkOption {