CLAUDE.md rule vs PreToolUse hook: both held 5 of 5, then the user said 'I authorize it'
This story is from 2026-09-21. It is preserved in the archive; the latest stories are on the live feed.
We gave Claude Code the same "never edit protected/ " rule two ways, as one line in CLAUDE.md and as a PreToolUse hook, and ran 29 headless sessions against a throwaway project. On an ordinary task both held every time (0 of 5 edits each, against 3 of 3 with neither). When the prompt said "I mainta…
Read the full story at DEV Community — AI ↗
Timeline · 1 report
- 2026-09-21 02:17 · DEV Community — AI
CLAUDE.md rule vs PreToolUse hook: both held 5 of 5, then the user said 'I authorize it'