spago2nix/mkbin.nix
justinwoo 3339d19826 update easy-purescirpt-nix dependency
mostly need to stop assuming i can actually build against latest
purescript, because nothing is stable
2021-05-08 13:12:35 +00:00

36 lines
652 B
Nix

# shell environment for generating bin/output.js
# Usage:
#
# nix-shell mkbin.nix
#
{ pkgs ? import <nixpkgs> { }
, nodejs ? pkgs.nodejs-10_x
}:
let
easy-purescript-nix = import
(
pkgs.fetchFromGitHub {
owner = "justinwoo";
repo = "easy-purescript-nix";
rev = "e00a54ca6bd0290e8301eff140d109c1f300e40d";
sha256 = "1yrnnpxkzs59ik5dj9v67ysn4viff775v24kizpl0ylf24c74928";
}
) {
inherit pkgs;
};
in
pkgs.mkShell {
nativeBuildInputs = [
easy-purescript-nix.purs-0_13_8
easy-purescript-nix.spago
nodejs
];
shellHook = ''
npm install
npm run mkbin
exit 0
'';
}