- Moved all hookify configuration files from `.claude/` to `.claude/hooks/` subdirectory for better organization - Added four new blocking hooks to prevent common error handling anti-patterns: - `block-broad-exception-handler`: Prevents catching generic `Exception` with only logging - `block-datetime-now-fallback`: Blocks returning `datetime.now()` as fallback on parse failures to prevent data corruption - `block-default
837 B
837 B
name, enabled, event, action, pattern
| name | enabled | event | action | pattern |
|---|---|---|---|---|
| block-code-quality-test-bash | true | bash | block | (sed|awk|cat\s*>|echo\s*>|tee|cp\s+.*code-quality.test.ts|mv\s+.*code-quality.test.ts|rm\s+.*code-quality.test.ts|>|>>).*code-quality.test.ts|code-quality.test.ts.*(>|>>||.*tee) |
BLOCKED: Protected File via Bash
The file src/test/code-quality.test.ts is protected from bash modifications.
Detected: Attempt to modify protected file via bash command.
Blocked commands include:
sededitingawkmodifications- Redirections (
>,>>) teewritescpoverwritesmvoperationsrmdeletions
Allowed operations:
cat(read only, without redirection)grep(searching)head,tail(viewing)
If you need to modify this file via bash, please ask the user for explicit permission first.