dgnum.eu/flake.nix

40 lines
1 KiB
Nix
Raw Permalink Normal View History

2023-06-14 01:59:59 +02:00
{
description = "Website for dgnum.eu";
inputs = {
nixpkgs.url = "nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
flake-compat = {
url = "github:edolstra/flake-compat";
flake = false;
};
2023-06-14 01:59:59 +02:00
};
outputs = { self, nixpkgs, flake-utils, ... }:
2023-06-14 01:59:59 +02:00
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages.${system};
ssg = pkgs.callPackage ./ssg { };
defaultInputs = with pkgs; [ nixfmt shellcheck ];
in
{
2023-06-14 01:59:59 +02:00
formatter = pkgs.nixfmt;
devShells = {
default = pkgs.mkShell { buildInputs = [ ssg ] ++ defaultInputs; };
ssg = pkgs.haskellPackages.shellFor {
packages = _: [ ssg ];
buildInputs = with pkgs.haskellPackages;
[ cabal-install ghcid hlint ] ++ defaultInputs;
};
};
packages = {
inherit ssg;
site = pkgs.callPackage ./site { inherit ssg; };
};
defaultPackage = self.packages.${system}.site;
});
}