From ca7a4a57c205dbfb9c9bb2407142f84f7a0a80f9 Mon Sep 17 00:00:00 2001 From: Yisroel Baum Date: Mon, 6 Apr 2026 22:03:12 +0300 Subject: [PATCH] create dev shell with nixos rebuild --- flake.nix | 28 +++++++++++++++++++--------- 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/flake.nix b/flake.nix index 85dc824..e8ba059 100644 --- a/flake.nix +++ b/flake.nix @@ -10,17 +10,27 @@ }; }; - outputs = { self, nixpkgs, home-manager, ... }@inputs: { - nixosConfigurations.nixos = nixpkgs.lib.nixosSystem { - modules = [ - ./configuration.nix - home-manager.nixosModules.home-manager - { + outputs = { self, nixpkgs, home-manager, ... }: + let + system = "x86_64-linux"; + in { + nixosConfigurations.nixos = nixpkgs.lib.nixosSystem { + modules = [ + ./configuration.nix + home-manager.nixosModules.home-manager + { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; home-manager.users.yisroel = ./home-manager/home.nix; - } - ]; + } + ]; + }; + devShells."${system}".default = let + pkgs = import nixpkgs { inherit system; }; + in pkgs.mkShell { + buildInputs = with pkgs; [ + nixos-rebuild + ]; + }; }; - }; }