let
  sources = import ./npins;

  pkgs = import sources.nixpkgs { };
  pre-commit-hooks = import sources.pre-commit-hooks;
in
{
  pre-commit-check = pre-commit-hooks.run {
    src = ./.;
    hooks = {
      go-mod-tidy = {
        enable = true;
        name = "go-mod-tidy";
        description = "Run `go mod tidy`";
        types_or = [ "go" "go-mod" ];
        entry = "${pkgs.go}/bin/go mod tidy";
        pass_filenames = false;
      };
    };
  };
}