A 15-line PreToolUse hook that stops Claude Code before rm -rf and force-push
This story is from 2026-10-09. It is preserved in the archive; the latest stories are on the live feed.
Project instructions tell a coding agent what you want . A hook is where you put the few things you never want to depend on the model remembering. Claude Code runs PreToolUse hooks before a tool call executes. If the hook exits with a blocking status, the call doesn't run and the reason goes back t…
Read the full story at DEV Community — AI ↗
Timeline · 1 report
- 2026-10-09 02:22 · DEV Community — AI
A 15-line PreToolUse hook that stops Claude Code before rm -rf and force-push