Claude Code HookGit38 installs

Validate Branch Name

Validate Git Flow branch naming conventions before checkout. Ensures branches follow the pattern: feature/*, release/v*.*.*, hotfix/*. Prevents creation of branches that don't follow Git Flow standards.

Install with the Claude Code Templates CLI
$ npx claude-code-templates@latest --hook="git/validate-branch-name" --yes

Requires Claude Code. The command adds this hook to your project's .claudedirectory — nothing runs on ToolZip's servers.

What's inside this hook

Component source

{

"description": "Validate Git Flow branch naming conventions before checkout. Ensures branches follow the pattern: feature/, release/v.., hotfix/*. Prevents creation of branches that don't follow Git Flow standards.",

"hooks": {

"PreToolUse": [

{

"matcher": "Bash",

"hooks": [

{

"type": "command",

"command": "python3 \"$CLAUDE_PROJECT_DIR\"/.claude/hooks/validate-branch-name.py"

}

]

}

]

}

}

Type
Hook
Category
Git
Installs
38
Source
GitHub ↗

Related Claude Code Hooks

HookGit

Conventional Commits

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.

72 installsView →
HookGit

Prevent Direct Push

Prevent direct pushes to protected branches (main, develop). Blocks git push commands targeting main or develop branches to enforce Git Flow workflow. Requires using feature/release/hotfix branches and pull requests instead of direct commits to protected branches.

54 installsView →
HookAutomation

Simple Notifications

Send desktop notifications when Claude Code finishes working or needs user input. Works on macOS and Linux systems.

1k installsView →
HookGit Workflow

Smart Commit

Intelligent git commit creation with automatic message generation and validation. Creates meaningful commits based on file changes.

398 installsView →
HookPre-Tool

Update Search Year

Automatically adds current year to WebSearch queries when no year is specified. This hook intercepts WebSearch tool usage and appends the current year to queries that don't already contain a year, ensuring search results are current and relevant.

361 installsView →
HookDevelopment Tools

Smart Formatting

Smart code formatting based on file type. Automatically formats code using Prettier, Black, gofmt, rustfmt, and other language-specific formatters.

326 installsView →

Catalog data and component content are sourced from the open-source davila7/claude-code-templates project (MIT license). ToolZip curates the listing and writes original descriptions; every component links back to its original source. Claude Code is a product of Anthropic. ToolZip is an independent catalog and is not affiliated with or endorsed by Anthropic.