blob: eb6bd17656641f9e8b8cce04275c62f90c311ebd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
{ nixpkgs ? import <nixpkgs> {}, compiler ? null }:
let
inherit (nixpkgs) pkgs;
haskellPackages = if compiler == null
then pkgs.haskellPackages
else pkgs.haskell.packages."${compiler}";
drv = import ./default.nix {};
in
pkgs.stdenv.lib.overrideDerivation drv.env (oldAttrs: {
nativeBuildInputs = oldAttrs.nativeBuildInputs ++ (with pkgs; [ cabal2nix gup postgresql ]) ++ (with haskellPackages; [ hlint stack yesod-bin alex ]);
shellHook = ''
${oldAttrs.shellHook}
export PROMPT_INFO="${oldAttrs.name}"
'';
})
|