home-services/.claude/settings.json
Nik Afiq 5c08e69bcb
All checks were successful
CI / test (push) Successful in 58s
CI / build-ai-gateway (push) Successful in 3m25s
CI / build-ha-gateway (push) Successful in 45s
CI / build-discord-bot (push) Successful in 40s
feat: add new skills and reviewers for architecture checks, README drift, and security audits
2026-07-22 23:28:50 +09:00

20 lines
1016 B
JSON

{
"hooks": {
"PreToolUse": [
{
"matcher": "Edit|Write",
"hooks": [
{
"type": "command",
"command": "jq -r '.tool_input.file_path // empty' | { read -r f; if [[ \"$f\" == *.env && \"$f\" != *.env.example ]]; then echo '{\"hookSpecificOutput\":{\"hookEventName\":\"PreToolUse\",\"permissionDecision\":\"deny\",\"permissionDecisionReason\":\"Refusing to edit a real .env file - it holds live secrets (HA_TOKEN, DISCORD_TOKEN). Edit the corresponding .env.example instead.\"}}'; fi; }"
},
{
"type": "command",
"command": "jq -r '.tool_input.file_path // empty' | { read -r f; if [[ \"$f\" == */gen/* ]]; then echo '{\"hookSpecificOutput\":{\"hookEventName\":\"PreToolUse\",\"permissionDecision\":\"deny\",\"permissionDecisionReason\":\"gen/ is committed buf-generated protobuf/gRPC code. Edit the source .proto file under proto/ and run buf generate instead.\"}}'; fi; }"
}
]
}
]
}
}