diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000..2f8cc5c --- /dev/null +++ b/shell.nix @@ -0,0 +1,15 @@ +{ nixpkgs ? import {}, compiler ? "default" }: + +let + + inherit (nixpkgs) pkgs; + + haskellPackages = if compiler == "default" + then pkgs.haskellPackages + else pkgs.haskell.packages.${compiler}; + + drv = haskellPackages.callPackage ./. {}; + +in + + if pkgs.lib.inNixShell then drv.env else drv