2024-06-29 17:53:57 +02:00
|
|
|
{
|
|
|
|
sources ? import ./npins,
|
|
|
|
nixpkgs ? sources.nixpkgs,
|
|
|
|
pkgs ? import nixpkgs { overlays = [ (import ./pkgs/overlay.nix) ]; },
|
|
|
|
}:
|
|
|
|
let
|
|
|
|
check = (import sources.git-hooks).run {
|
|
|
|
src = ./.;
|
|
|
|
|
|
|
|
hooks = {
|
|
|
|
# Nix Hooks
|
|
|
|
statix.enable = true;
|
|
|
|
deadnix.enable = true;
|
|
|
|
rfc101 = {
|
|
|
|
enable = true;
|
|
|
|
|
|
|
|
name = "RFC-101 formatting";
|
|
|
|
entry = "${pkgs.lib.getExe pkgs.nixfmt-rfc-style}";
|
|
|
|
files = "\\.nix$";
|
|
|
|
};
|
|
|
|
|
|
|
|
# Misc Hooks
|
|
|
|
commitizen.enable = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
in
|
|
|
|
{
|
|
|
|
inherit pkgs;
|
2024-07-18 22:25:44 +02:00
|
|
|
tests = import ./tests { inherit pkgs; };
|
2024-06-29 17:53:57 +02:00
|
|
|
shell = pkgs.mkShell {
|
|
|
|
name = "binary-cache";
|
|
|
|
buildInputs = check.enabledPackages;
|
|
|
|
shellHook = ''
|
|
|
|
${check.shellHook}
|
|
|
|
'';
|
|
|
|
|
|
|
|
};
|
|
|
|
}
|