Use home manager with nixos, not as separate module

This commit is contained in:
xenia 2024-06-23 23:23:26 +02:00
parent 3bafc3e76d
commit 90e14b4380

View File

@ -82,44 +82,6 @@
]; ];
}; };
homeConfigurations."coral" =
let
system = "x86_64-linux";
pkgs = mkPkgs system;
home = mkHome {
username = "coral";
home-dir = "/home/coral";
prompt-color = 243;
inherit system pkgs;
};
in home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [
home
];
};
homeConfigurations."xenia" =
let
system = "x86_64-linux";
pkgs = mkPkgs system;
home = mkHome {
username = "xenia";
home-dir = "/home/xenia";
prompt-color = 205;
inherit system pkgs;
};
pc = mkPC { inherit system pkgs; };
in home-manager.lib.homeManagerConfiguration {
inherit pkgs;
modules = [
home
pc
];
};
darwinConfigurations."Joe-Bidens-MacBook-Pro" = darwinConfigurations."Joe-Bidens-MacBook-Pro" =
let let
system = "aarch64-darwin"; system = "aarch64-darwin";
@ -147,6 +109,31 @@
eth-interface = "enp0s31f6"; eth-interface = "enp0s31f6";
static-ip = "192.168.0.199"; static-ip = "192.168.0.199";
}; };
coral =
let
system = "x86_64-linux";
pkgs = mkPkgs system;
home = mkHome {
username = "coral";
home-dir = "/home/coral";
prompt-color = 243;
inherit system pkgs;
};
in { home = home; };
xenia =
let
system = "x86_64-linux";
pkgs = mkPkgs system;
home = mkHome {
username = "xenia";
home-dir = "/home/xenia";
prompt-color = 205;
inherit system pkgs;
};
pc = mkPC { inherit system pkgs; };
in { home = home; pc = pc; };
in in
nixpkgs.lib.nixosSystem { nixpkgs.lib.nixosSystem {
inherit system; inherit system;
@ -155,6 +142,14 @@
base base
graphical graphical
networking networking
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.coral = coral.home;
home-manager.users.xenia = xenia.home;
}
{ home-manager.users.xenia = xenia.pc; }
]; ];
}; };
}; };