This commit is contained in:
iFargle 2023-08-15 18:56:20 +09:00
parent b55d029d8e
commit 9a1a5e0702
5 changed files with 24 additions and 17 deletions

View file

@ -39,6 +39,7 @@
# Variables - Remember to set these # Variables - Remember to set these
hostname = "nixos-laptop"; # Should probably set this in a minimal configuration.nix? hostname = "nixos-laptop"; # Should probably set this in a minimal configuration.nix?
system = "x86_64-linux"; system = "x86_64-linux";
hmStateVersion = "23.05";
pkgs = import unstable-nixpkgs { pkgs = import unstable-nixpkgs {
inherit system; inherit system;
@ -73,12 +74,12 @@
useUserPackages = true; useUserPackages = true;
users.albert.imports = [ users.albert.imports = [
({ config, ... }: import ./users/albert/home.nix { ({ config, ... }: import ./users/albert/home.nix {
inherit config pkgs hostname; inherit config pkgs hostname hmStateVersion;
}) })
]; ];
users.root.imports = [ users.root.imports = [
({ config, ... }: import ./users/root/home.nix { ({ config, ... }: import ./users/root/home.nix {
inherit config pkgs hostname; inherit config pkgs hostname hmStateVersion;
}) })
]; ];
}; # home-manager }; # home-manager

9
home-manager/default.nix Normal file
View file

@ -0,0 +1,9 @@
{ config, pkgs, hostname, ... }: {
imports = [
./bash.nix
./btop.nix
./firefox.nix
./git.nix
./neovim.nix
];
}

View file

@ -1,7 +1,7 @@
{ imports, ... }: { { imports, ... }: {
imports = [ imports = [
# imports.nixos-hardware.nixosModules.lenovo-thinkpad-p1 # imports.nixos-hardware.nixosModules.lenovo-thinkpad-p1
./home-manager
./nixos ./nixos
# home-manager is imported from users/user/home.nix
]; ];
} }

View file

@ -1,14 +1,10 @@
{ config, pkgs, hostname, ... }: { { config, pkgs, hostname, hmStateVersion, ... }: {
home.stateVersion = "23.05"; home.stateVersion = ${hmStateVersion};
imports = [ imports = [
# Host specific Configs: # Host specific Configs:
../../hosts/${hostname}/home-manager/default.nix ../../hosts/${hostname}/home-manager
# Universal Configs: # Universal Configs:
../../home-manager/git.nix ../../home-manager
../../home-manager/neovim.nix
../../home-manager/bash.nix
../../home-manager/firefox.nix
../../home-manager/btop.nix
]; ];
} }

View file

@ -1,9 +1,10 @@
{ config, pkgs, hostname, ... }: { { config, pkgs, hostname, hmStateVersion, ... }: {
home.stateVersion = "23.05"; home.stateVersion = ${hmStateVersion};
imports = [ imports = [
../../home-manager/git.nix # Host specific Configs:
../../home-manager/neovim.nix # ../../hosts/${hostname}/home-manager
../../home-manager/bash.nix
../../home-manager/btop.nix # Universal Configs:
../../home-manager
]; ];
} }