Add branch protection hooks to the current repo. Blocks pushes to main/master and force pushes via Claude Code. Use when setting up a production repo or when the user says "protect this repo" or "add branch guardrails".
From chad-toolsnpx claudepluginhub metcalfc/claude-plugin --plugin chad-toolsThis skill uses the workspace's default tool permissions.
Designs and optimizes AI agent action spaces, tool definitions, observation formats, error recovery, and context for higher task completion rates.
Enables AI agents to execute x402 payments with per-task budgets, spending controls, and non-custodial wallets via MCP tools. Use when agents pay for APIs, services, or other agents.
Compares coding agents like Claude Code and Aider on custom YAML-defined codebase tasks using git worktrees, measuring pass rate, cost, time, and consistency.
Add branch protection to the current repo's Claude Code config:
.claude/settings.json exists in the repo root.claude/settings.json with this content:{
"hooks": {
"PreToolUse": [
{
"matcher": "Bash",
"hooks": [
{
"type": "command",
"command": "bash -c 'CMD=$(cat | jq -r \".tool_input.command // empty\"); if echo \"$CMD\" | grep -qE \"git push.*(main|master)\"; then echo \"BLOCKED: Use a feature branch and PR.\" >&2; exit 2; fi; if echo \"$CMD\" | grep -qE \"git push (-f|--force)\"; then echo \"BLOCKED: Force push requires explicit approval.\" >&2; exit 2; fi'"
}
]
}
]
}
}