flake.nix: move main flake into config block
grrr why do people always insist on dumping options into the main block of the module
This commit is contained in:
parent
41be6a0642
commit
c7d841b3e8
24
flake.nix
24
flake.nix
@ -1,3 +1,4 @@
|
||||
# vim: set foldmethod=marker:
|
||||
{
|
||||
description = "NixOS Configuration";
|
||||
|
||||
@ -109,11 +110,15 @@
|
||||
flake-parts,
|
||||
...
|
||||
} @ inputs:
|
||||
flake-parts.lib.mkFlake {inherit inputs;} ({
|
||||
flake-parts.lib.mkFlake {inherit inputs;} (
|
||||
{
|
||||
inputs,
|
||||
self,
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
} @ flakeArgs: let
|
||||
# {{{
|
||||
inherit (inputs) nixpkgs nixpkgs-unstable;
|
||||
inherit (self) outputs;
|
||||
# inputs is already defined
|
||||
@ -400,7 +405,19 @@
|
||||
}
|
||||
// builtins.removeAttrs args
|
||||
["system" "nixpkgs" "home-manager" "modules" "username" "homeDirectory" "stateVersion" "entrypoint" "config"]);
|
||||
# }}}
|
||||
in {
|
||||
# flake-parts imports
|
||||
imports = [
|
||||
./flake
|
||||
];
|
||||
|
||||
config = {
|
||||
# flake-parts systems (still uses nix-systems)
|
||||
systems = import inputs.systems;
|
||||
|
||||
debug = lib.mkDefault true;
|
||||
|
||||
flake = {
|
||||
# for repl debugging via :lf .
|
||||
inherit inputs vars;
|
||||
@ -555,8 +572,9 @@
|
||||
};
|
||||
};
|
||||
};
|
||||
systems = (import inputs.systems);
|
||||
}); # end outputs
|
||||
};
|
||||
}
|
||||
); # end outputs
|
||||
}
|
||||
# end flake
|
||||
|
||||
|
6
flake/default.nix
Normal file
6
flake/default.nix
Normal file
@ -0,0 +1,6 @@
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./packages.nix
|
||||
];
|
||||
}
|
2
flake/packages.nix
Normal file
2
flake/packages.nix
Normal file
@ -0,0 +1,2 @@
|
||||
{ ... }: {
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user