Dev setup: correct the hook claim, ship an opt-in committed hook
The naming check was documented as an auto-running pre-commit hook, but .git/hooks is never cloned - a fresh clone had nothing and CI is the real enforcement. Ship .githooks/pre-commit for opt-in local use.
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -3,3 +3,4 @@
|
||||
# Shell scripts must stay LF so Git Bash on Windows can run them
|
||||
*.sh text eol=lf
|
||||
scripts/check-naming-and-style.sh text eol=lf
|
||||
.githooks/pre-commit text eol=lf
|
||||
|
||||
5
.githooks/pre-commit
Executable file
5
.githooks/pre-commit
Executable file
@@ -0,0 +1,5 @@
|
||||
#!/usr/bin/env bash
|
||||
# Committed pre-commit hook. Activate per clone with:
|
||||
# git config core.hooksPath .githooks
|
||||
# Runs the naming/style gate; blocks the commit on failure.
|
||||
exec bash "$(git rev-parse --show-toplevel)/scripts/check-naming-and-style.sh"
|
||||
Reference in New Issue
Block a user