Move Nix files into a nix directory
Move everything from `config` to the root level.
This commit is contained in:
parent
9f47df62b5
commit
69a397e624
124 changed files with 14 additions and 14 deletions
64
nix/lib/nixos/default.nix
Normal file
64
nix/lib/nixos/default.nix
Normal file
|
@ -0,0 +1,64 @@
|
|||
{
|
||||
inputs,
|
||||
outputs,
|
||||
nixos-hardware,
|
||||
pkgs,
|
||||
self,
|
||||
username,
|
||||
}:
|
||||
{
|
||||
desktop ? false,
|
||||
hostname,
|
||||
}:
|
||||
let
|
||||
configuration = import ./configuration.nix {
|
||||
inherit
|
||||
outputs
|
||||
desktop
|
||||
hostname
|
||||
inputs
|
||||
self
|
||||
;
|
||||
};
|
||||
hardwareConfiguration = import ./hardware-configuration.nix;
|
||||
in
|
||||
inputs.nixpkgs.lib.nixosSystem {
|
||||
modules = [
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager = {
|
||||
extraSpecialArgs = {
|
||||
inherit
|
||||
inputs
|
||||
desktop
|
||||
self
|
||||
username
|
||||
;
|
||||
};
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
users."${username}" = import "${self}/nix/home/${username}";
|
||||
};
|
||||
}
|
||||
|
||||
(import ../../modules/nixos/autorandr.nix)
|
||||
(import ../../modules/nixos/i3.nix {
|
||||
inherit
|
||||
inputs
|
||||
pkgs
|
||||
self
|
||||
username
|
||||
;
|
||||
})
|
||||
|
||||
configuration
|
||||
hardwareConfiguration
|
||||
|
||||
# TODO: only for "lemp11".
|
||||
nixos-hardware.nixosModules.common-cpu-intel
|
||||
nixos-hardware.nixosModules.common-gpu-intel
|
||||
nixos-hardware.nixosModules.common-pc-laptop
|
||||
nixos-hardware.nixosModules.common-pc-laptop-hdd
|
||||
nixos-hardware.nixosModules.system76
|
||||
];
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue