diff options
Diffstat (limited to 'shell.nix')
-rw-r--r-- | shell.nix | 28 |
1 files changed, 26 insertions, 2 deletions
diff --git a/shell.nix b/shell.nix index d2c4c458..a0eb33c8 100644 --- a/shell.nix +++ b/shell.nix @@ -1,3 +1,27 @@ -{ system ? builtins.currentSystem }: +let -(builtins.getFlake (toString ./.)).devShells.${system}.default + sources = import ./nix/sources.nix; + + nixpkgs = sources.nixpkgs; + + pkgs = import nixpkgs { }; + +in +pkgs.mkShell rec { + + name = "nixfiles-shell"; + + buildInputs = with pkgs; [ + niv + deploy-rs + (pkgs.callPackage "${sources.agenix}/pkgs/agenix.nix" { }) + (import sources.home-manager { inherit pkgs; }).home-manager + ]; + + shellHook = '' + export HOST=$(hostname) + export NIX_PATH="nixpkgs=${nixpkgs}:home-manager=${sources."home-manager"}:darwin=${sources.nix-darwin}:darwin-config=$PWD/system/$HOST.nix:private=$PWD/private:nixpkgs-overlays=$PWD/overlays:nix-index-database=${sources.nix-index-database}"; + export HOME_MANAGER_CONFIG="./user/$HOST.nix" + ''; + +} |