flake.nix: update default NixOS config with home-manager options

This commit is contained in:
Gabriel Arazas 2022-07-09 07:08:27 +08:00
parent 877622db77
commit 3d9494d92a
2 changed files with 10 additions and 6 deletions

View File

@ -174,6 +174,16 @@
nix.extraOptions = '' nix.extraOptions = ''
experimental-features = nix-command flakes experimental-features = nix-command flakes
''; '';
# The global configuration for the home-manager module.
home-manager.useUserPackages = true;
home-manager.useGlobalPkgs = true;
home-manager.sharedModules =
lib'.modulesToList (lib'.filesToAttr ./modules/home-manager);
home-manager.extraSpecialArgs = {
lib = lib';
inherit inputs system self;
};
}; };
mkUser = { system ? defaultSystem, extraModules ? [ ] }: mkUser = { system ? defaultSystem, extraModules ? [ ] }:

View File

@ -65,12 +65,6 @@ in {
} is not found in the `./users/home-manager` directory."; } is not found in the `./users/home-manager` directory.";
}]; }];
# The global configuration for the home-manager module.
home-manager.useUserPackages = true;
home-manager.useGlobalPkgs = true;
home-manager.sharedModules = lib.modulesToList homeManagerModules;
home-manager.extraSpecialArgs = { inherit inputs; };
# Mapping each users to the respective user configuration. # Mapping each users to the respective user configuration.
# Setting users for home-manager. # Setting users for home-manager.
home-manager.users = mapUsers (user: _: home-manager.users = mapUsers (user: _: