mirror of
https://github.com/davila7/claude-code-templates.git
synced 2026-09-19 01:30:23 +08:00
92fdaa1f87
- Created conventional-commits.py for commit message validation - Created prevent-direct-push.py for protected branch enforcement - Updated all hook JSONs to use Python scripts with proper JSON output - All hooks now use permissionDecision: "deny" for proper blocking 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
17 lines
598 B
JSON
17 lines
598 B
JSON
{
|
|
"description": "Enforce conventional commit message format for all git commits. Validates commit messages follow the pattern: type(scope): description. Supported types: feat, fix, docs, style, refactor, perf, test, chore, ci, build, revert. Ensures consistent commit history for changelog generation and semantic versioning.",
|
|
"hooks": {
|
|
"PreToolUse": [
|
|
{
|
|
"matcher": "Bash",
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "python3 \"$CLAUDE_PROJECT_DIR\"/.claude/hooks/conventional-commits.py"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
}
|