From 7c9a7b75952d2594d500a656deacb6b560aaf00e Mon Sep 17 00:00:00 2001 From: Michael Hoang Date: Mon, 6 Dec 2021 15:19:49 +1100 Subject: [PATCH] flake.nix: Import `shell.nix` as `devShell` --- flake.nix | 3 ++- shell.nix | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index 3fc4d34..23cd2d5 100644 --- a/flake.nix +++ b/flake.nix @@ -7,7 +7,8 @@ flake-utils.lib.eachDefaultSystem (system: let pkgs = nixpkgs.legacyPackages.${system}; in { - defaultPackage = pkgs.callPackage ./default.nix {}; + defaultPackage = pkgs.callPackage ./default.nix { }; + devShell = pkgs.callPackage ./shell.nix { }; }) // { overlay = final: prev: { nix-direnv = final.callPackage ./default.nix { }; diff --git a/shell.nix b/shell.nix index 3c89d29..89ef822 100644 --- a/shell.nix +++ b/shell.nix @@ -1,4 +1,6 @@ -with import {}; +{ pkgs ? import {} }: + +with pkgs; mkShell { nativeBuildInputs = [ python3