Commit 9b35472
feat: add mix githooks.install to activate the repo's git hooks (#51)
## Summary
Closes #50.
`githooks/commit-msg` exists and correctly calls
`ci/validate_conventional_commit.sh`, but `core.hooksPath` was never
actually configured on any local clone - the hook never fired, which is
how `fix!(docs)`/`docs!(licence)` (wrong `!` position) got committed
without ever being caught before push.
Adds `mix githooks.install` (`git config core.hooksPath githooks`) and
mentions it in the Readme's Development section so it's actually
discoverable.
Related: `main` now also requires the `Test` and `Validate Commit
Subjects` checks to pass before merge, with no admin override - so even
if the local hook is skipped, CI backstops it.
## Test plan
- [x] `mix test` - 182 passed
- [x] `mix format --check-formatted` - clean
- [x] Ran `mix githooks.install` for real, then fed a malformed subject
(`fix!(docs): ...`) through the now-active `githooks/commit-msg` hook
directly - correctly rejected
- [x] `asciidoctor -o /dev/null Readme.adoc` renders clean
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>1 parent 567b508 commit 9b35472
2 files changed
Lines changed: 30 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
265 | 265 | | |
266 | 266 | | |
267 | 267 | | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
268 | 277 | | |
269 | 278 | | |
270 | 279 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
0 commit comments