Open abelsiqueira opened 4 days ago
I've implemented the hook as an example here: abelsiqueira/BestieTemplate.jl#472 The logic and script are in the user's side, but the code would be pretty much the same.
Sure, I’m open to PRs adding this here
Thanks! I'll submit something soon
We are considering how to best use ExplicitImports in Bestie (abelsiqueira/BestieTemplate.jl#349 and abelsiqueira/BestieTemplate.jl#217). Our current idea is to have a pre-commit hook, like we have for JuliaFormatter and other non-Julia tools. These hooks also form our Lint workflow, which ensures that even if someone is not using pre-commit, the hooks still run at each PR. For that to work, we'll need a definition of the pre-commit-hook for ExplicitImports. Although it's possible to create a completely separate repo for that, it's common to have it as part of the main repo (e.g., https://github.com/domluna/JuliaFormatter.jl/blob/master/.pre-commit-hooks.yaml).
Are you open to adding a
.pre-commit-hooks.yml
file here (and possibly an auxiliary script file)?From what I tried so far, it would probably be something like the two files below, although I'm open to suggestions