binary-cache/default.nix

39 lines
743 B
Nix
Raw Permalink Normal View History

2024-06-29 15:53:57 +00: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 20:25:44 +00:00
tests = import ./tests { inherit pkgs; };
2024-06-29 15:53:57 +00:00
shell = pkgs.mkShell {
name = "binary-cache";
buildInputs = check.enabledPackages;
shellHook = ''
${check.shellHook}
'';
};
}