From 0afbdaa261653e73a4f2f39d7529114989474a64 Mon Sep 17 00:00:00 2001 From: Quentin Aristote Date: Sat, 11 Feb 2023 18:12:03 +0100 Subject: factor out common configuration options --- flake.nix | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index ff8161a..07f44e4 100644 --- a/flake.nix +++ b/flake.nix @@ -1,11 +1,20 @@ { inputs = { - my-nixpkgs = "git+file:///home/qaristote/code/nix/my-nixpkgs"; + my-nixpkgs.url = "git+file:///home/qaristote/code/nix/my-nixpkgs"; + nixos-hardware.url = "github:NixOS/nixos-hardware/master"; + home-manager.url = "github:nix-community/home-manager"; }; - outputs = { self, nixpkgs }: { + + outputs = { self, nixpkgs, my-nixpkgs, nixos-hardware, home-manager }: + let system = "x86_64-linux"; in { nixosConfigurations.latitude-7490 = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - modules = [ ./nixos/configuration.nix ]; + inherit system; + specialArgs = { inherit nixos-hardware home-manager; home.qaristote = import ./home; }; + modules = [ my-nixpkgs.nixosModules.personal ./nixos ]; + }; + homeConfigurations.qaristote = home-manager.lib.homeManagerConfiguration { + pkgs = nixpkgs.legacyPackages."${system}"; + modules = [ ./home ]; }; }; } -- cgit v1.2.3