home: direnv: set 'DIRENV_DEFAULT_FLAKE' as needed
All checks were successful
ci/woodpecker/push/check Pipeline was successful

This commit is contained in:
Bruno BELANYI 2024-04-15 14:08:00 +00:00
parent 6a22a80d42
commit b735eb4b98

View file

@ -7,8 +7,8 @@ in
enable = my.mkDisableOption "direnv configuration";
defaultFlake = mkOption {
type = types.str;
default = "nixpkgs";
type = with types; nullOr str;
default = null;
example = "pkgs";
description = ''
Which flake from the registry should be used for
@ -39,7 +39,7 @@ in
in
lib.my.genAttrs' files linkLibFile;
home.sessionVariables = {
home.sessionVariables = lib.mkIf (cfg.defaultFlake != null) {
DIRENV_DEFAULT_FLAKE = cfg.defaultFlake;
};
};