home/common/nix: install direnv

This commit is contained in:
NullBite 2024-04-21 13:03:12 -04:00
parent ceee1b418c
commit 21db6fe9ff
Signed by: nullbite
GPG Key ID: 6C4D545385D4925A

View File

@ -21,6 +21,14 @@ in {
}
(lib.mkIf standalone {
# direnv is a tool to automatically load shell environments upon entering
# a directory. nix-direnv has an extensionn to keep nix shells in the
# system's gcroots so shells can be used after a gc without rebuilding.
programs.direnv = {
enable = lib.mkDefault true;
nix-direnv.enable = lib.mkDefault true;
};
home.sessionVariables.NIX_PATH = "nixpkgs=${nixpkgs}\${NIX_PATH:+:\${NIX_PATH}}";
nix.registry = {
nixpkgs = {