Convert home-manager to flakes

Instead of calling the home manager directly in the user's list, we add
a command for the user to invoke "hms" and have their environment setup
in the way that Greg likes.
This commit is contained in:
Greg Hellings
2022-08-02 01:50:50 -05:00
parent 8c69ccd3b2
commit 78704b5c88
10 changed files with 95 additions and 19 deletions
+9 -5
View File
@@ -12,15 +12,15 @@
url = "github:nix-community/home-manager/release-22.05";
inputs.nixpkgs.follows = "nixpkgs";
};
nur.url = "github:nix-community/NUR";
nurpkgs.url = "github:nix-community/NUR";
};
outputs = {nixpkgs, nixunstable, agenix, home-manager, nur, self}@inputs:
outputs = {nixpkgs, nixunstable, agenix, home-manager, nurpkgs, self}@inputs:
let
local_overlay = import ./overlays;
mods = hostname: [
{ nixpkgs.overlays = [ nur.overlay local_overlay ]; }
{ nixpkgs.overlays = [ nurpkgs.overlay local_overlay ]; }
agenix.nixosModule
./modules
./profiles/base
@@ -28,8 +28,6 @@
home-manager.nixosModules.home-manager {
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.greg = import ./home/home.nix "greg";
home-manager.users.root = import ./home/home.nix "root";
home-manager.extraSpecialArgs = {
inherit nixunstable;
};
@@ -54,5 +52,11 @@
};
defaultPackage."x86_64-linux" = inputs.self.nixosConfigurations.iso.config.system.build.isoImage;
homeConfigurations = (
import ./home {
inherit nixpkgs nixunstable agenix home-manager nurpkgs;
}
);
};
}