feat: Add a gitHook definition

This commit is contained in:
Tom Hubrecht 2024-12-30 12:16:00 +01:00
parent d3f88b1879
commit 8815dfc28d
Signed by: thubrecht
SSH key fingerprint: SHA256:r+nK/SIcWlJ0zFZJGHtlAoRwq1Rm+WcKAm5ADYMoQPc

View file

@ -38,6 +38,8 @@ let
package = pkgs.reuse;
};
actions-validator = workflows.gitHook { stages = [ "pre-push" ]; };
commitizen.enable = true;
};
};
@ -97,6 +99,12 @@ in
in
{
shellHook = project.config.installationScript;
gitHook = recursiveUpdate {
enable = true;
name = "Actions validator";
entry = getExe pkgs.action-validator;
files = "\\.${project.config.platform}/workflows/.*\\.ya?ml";
};
};
lib = rec {