Open willardmr opened 1 year ago
List of github hooks available, with an explanation for the ones that seem not to be relevant:
pre-commit
prepare-commit-msg
/ commit-msg
: no need to mess with commit messagepost-commit
applypatch-msg
/ pre-applypatch
/ post-applypatch
: email workflows, not very relevantpre-rebase
/ post-rewrite
/ post-checkout
: no new code per sepost-merge
pre-push
pre-auto-gc
: no need during garbage collectionpre-receive
/ update
/ post-receive
: at this we've lost the benefits of hooks for our use caseI suggest we provide the hooks pre-commit
/ post-commit
/ post-merge
/ pre-push
by default, with documentation. The other can be derived from them, would they ever be necessary.
Source: https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks
I may have lead you down the wrong path with the title of this issue.
I might be a bit confused about the terminology, but it looks to me like we just want to provide a github action and give people recommendations for how to use the action with github events. These hooks don't seem super useful to me and I am more used to just adding actions to github workflows. Here is an example of an action I use: superfly/flyctl-actions@1.3 and I just add it to my github workflow as a step. Does that make sense?
https://docs.github.com/en/actions/using-workflows/reusing-workflows I think this might be what you have in mind ? Essentially we just make a workflow with input and outputs such that other workflows can call it. This might be the first step to have it listed on the marketplace.
Yeah exactly! I have used those in the past and they work really well. We may want to dockerize our tool since a lot of other workflows seem to do that, but besides that seems like the easiest and most useful thing. What do you think?
Someone should be able to easily integrate sustainable CI into their github hooks.