Safety Net: Stop Claude Deleting Your Files Before the Command Runs
A free, open-source guard for Claude Code. Before Claude runs a command or opens a file, it checks what that call would really do, and blocks hard resets, force pushes, risky rm -rf and reads of your secret keys
Claude Code runs real commands on your machine. Most are harmless, but one wrong git reset --hard or rm -rf can wipe work you never committed. CC Safety Net sits in front of every tool call: it parses what the command would actually do, and if it is destructive the call never runs and Claude is told why. Safe calls such as git status run normally.
What it blocks (from the README)
- Destructive Git: git reset --hard, git push --force.
- Destructive file commands: rm -rf on dangerous targets.
- The same commands hidden inside bash -c or python -c. It reads what the command does, so wrapping it or reordering flags doesn't get past it.
- Secrets: SSH keys, .env files, ~/.aws and coding-CLI login files, from both the shell and Claude's own file tools.
Free, for your email
Get the full setup steps + the copy-paste setup prompt
The rest of this guide (3 more sections, 1 copy-paste prompt) opens right here. The setup prompt, one paste into Claude that sets it all up, comes by email only. Use your real address.
Unlocks: Set it up · The catch · Sources
50,000+ follow where these guides come from. No spam, reply “unsubscribe” any time.