hooks-config.json
来自
cli/templates/level-2/
json
{
"hooks": {
"PreToolUse": [{
"matcher": "Bash",
"hooks": [
{"type": "command", "command": ".claude/hooks/pre-bash-firewall.sh"},
{"type": "command", "command": ".claude/hooks/pre-bash-dep-guard.sh"}
]
}],
"PostToolUse": [{
"matcher": "Write|Edit",
"hooks": [
{"type": "command", "command": ".claude/hooks/post-edit-format.sh"},
{"type": "command", "command": ".claude/hooks/post-write-size-guard.sh"}
]
}],
"PreCompact": [{
"matcher": "auto",
"hooks": [
{"type": "command", "command": ".claude/hooks/pre-compact-preserve.sh"}
]
}]
}
}