feat: namespace arg, inputs for packages and overlays, get lib from root, add checks

This commit is contained in:
Jake Hamilton 2024-05-22 19:03:29 -07:00
parent d6b766939a
commit b2e6364075
No known key found for this signature in database
GPG key ID: 9762169A1B35EA68
13 changed files with 112 additions and 38 deletions

View file

@ -116,6 +116,7 @@ in {
format = "home";
inputs = snowfall-lib.flake.without-src user-inputs;
namespace = snowfall-config.namespace;
# NOTE: home-manager has trouble with `pkgs` recursion if it isn't passed in here.
inherit pkgs lib;
@ -345,9 +346,11 @@ in {
# NOTE: specialArgs are not propagated by Home-Manager without this.
# However, not all specialArgs values can be set when using `_module.args`.
_module.args =
builtins.removeAttrs (users.users.${name}.specialArgs or {})
["options" "config" "lib" "pkgs" "specialArgs" "host"];
_module.args = builtins.removeAttrs ((users.users.${name}.specialArgs or {})
// {
namespace = snowfall-config.namespace;
})
["options" "config" "lib" "pkgs" "specialArgs" "host"];
};
home-manager = {