seal-blog/flake.nix

39 lines
928 B
Nix
Raw Normal View History

2023-04-10 19:42:25 -04:00
{
description = "A Nix flake for my long-running seal blog";
inputs = {
2023-08-02 17:02:43 -04:00
nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05";
2023-04-10 19:42:25 -04:00
utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, utils }:
utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages.${system};
ghc' = pkgs.haskellPackages.ghcWithHoogle (self: with self; [
2023-04-19 18:42:09 -04:00
dhall
2023-04-10 19:42:25 -04:00
hakyll
neat-interpolation
random
split
]);
in
{
devShells.default = pkgs.mkShell {
name = "hakyll-shell";
buildInputs = with pkgs.haskellPackages;
[
ghc'
hlint
2023-04-19 18:42:09 -04:00
haskell-language-server
2023-08-02 17:01:35 -04:00
(pkgs.writeShellScriptBin "build-site" ''
${ghc'}/bin/ghc --make website/site -outputdir dist -static -O2
'')
2023-04-10 19:42:25 -04:00
];
};
});
}