Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions modules/_types.nix
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ let
- adding specialArgs when absolutely required.
'';
example = lib.literalExpression "inputs.nixpkgs.lib.nixosSystem";
type = lib.types.unspecified;
type = lib.types.raw;
default =
{
nixos = inputs.nixpkgs.lib.nixosSystem;
Expand Down Expand Up @@ -147,6 +147,14 @@ let
class = strOpt "home management nix class" "homeManager";
aspect = strOpt "main aspect name" config.name;
description = strOpt "home description" "home.${config.userName}@${config.system}";
pkgs = lib.mkOption {
description = ''
nixpkgs instance used to build the home configuration.
'';
example = lib.literalExpression ''inputs.nixpkgs.legacyPackages.''${home.system}'';
type = lib.types.raw;
default = inputs.nixpkgs.legacyPackages.${config.system};
};
instantiate = lib.mkOption {
description = ''
Function used to instantiate the home configuration.
Expand All @@ -160,7 +168,7 @@ let
- adding extraSpecialArgs when absolutely required.
'';
example = lib.literalExpression "inputs.home-manager.lib.homeManagerConfiguration";
type = lib.types.unspecified;
type = lib.types.raw;
default =
{
homeManager = inputs.home-manager.lib.homeManagerConfiguration;
Expand Down
12 changes: 4 additions & 8 deletions modules/config.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
config,
lib,
withSystem,
...
}:
let
Expand All @@ -28,13 +27,10 @@ let

homeConfiguration =
home:
withSystem home.system (
{ pkgs, ... }:
home.instantiate {
inherit pkgs;
modules = [ home.mainModule ];
}
);
home.instantiate {
pkgs = home.pkgs;
modules = [ home.mainModule ];
};

cfgs = (build osConfiguration config.den.hosts) ++ (build homeConfiguration config.den.homes);

Expand Down