home-environment: use lazyAttrsOf
for home.sessionVariables
(#3541)
* home-environment: use `lazyAttrsOf` for `home.sessionVariables` `attrs` has unreasonable merge semantics and is deprecated. `attrsOf` doesn't support variables depending on each other as is recommended in the option's description. * home-environment: restrict `sessionVariables` type The consumer is `toString`, but we don't want to accept e.g. lists.
This commit is contained in:
parent
079a33a015
commit
c8f6322303
|
@ -256,7 +256,7 @@ in
|
||||||
|
|
||||||
home.sessionVariables = mkOption {
|
home.sessionVariables = mkOption {
|
||||||
default = {};
|
default = {};
|
||||||
type = types.attrs;
|
type = with types; lazyAttrsOf (oneOf [ str path int float ]);
|
||||||
example = { EDITOR = "emacs"; GS_OPTIONS = "-sPAPERSIZE=a4"; };
|
example = { EDITOR = "emacs"; GS_OPTIONS = "-sPAPERSIZE=a4"; };
|
||||||
description = ''
|
description = ''
|
||||||
Environment variables to always set at login.
|
Environment variables to always set at login.
|
||||||
|
|
Loading…
Reference in a new issue