You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
mcwhirter.io/default.nix

22 lines
591 B

{ nixpkgs ? import <nixpkgs> { }, compiler ? "default" }:
let
inherit (nixpkgs) pkgs;
haskellPackages = if compiler == "default" then
pkgs.haskellPackages
else
pkgs.haskell.packages.${compiler};
mcwhirter-io = haskellPackages.callPackage ./mcwhirter-io.nix { };
in nixpkgs.stdenv.mkDerivation {
name = "mcwhirter-io-website";
buildInputs = [ mcwhirter-io ];
src = ./.;
buildPhase = ''
echo "Setting LC_ALL to C.UTF-8 to avoid invalid byte sequence."
export LC_ALL=C.UTF-8
site build
'';
installPhase = ''
mkdir $out
cp -R _site/* $out
'';
}