git-hooks.nix
git-hooks.nix copied to clipboard
[flake-parts] Use git-hooks as non-flake input
The flake-parts template currently suggests using it as a flake input:
https://github.com/cachix/git-hooks.nix/blob/cd1af27aa85026ac759d5d3fccf650abe7e1bbf0/template/flake.nix#L6-L7
This brings in a bunch of transitive inputs that the user does not strictly need, forcing setting up of follows like:
git-hooks.inputs = {
nixpkgs.follows = "nixpkgs";
nixpkgs-stable.follows = "nixpkgs";
};
gitignore.follows = "git-hooks/gitignore";
gitignore.inputs.nixpkgs.follows = "nixpkgs";
gitignore.inputs.flake-compat = { };
Therefore, should we just change the template to reference git-hooks as a non-flake input? viz.:
git-hooks.url = "github:cachix/git-hooks.nix";
git-hooks.flake = false;
...
# In imports
(inputs.git-hooks + /flake-module.nix)