Show HN: Do-over, undo for AI agent shell commands Developer built Do-over, a tool that plugs into Claude Code's hooks to snapshot files before AI agent shell commands run, protecting untracked, ignored, and out-of-repo files from destructive actions like git checkout, git clean -fd, and git reset --hard. The tool addresses data loss incidents reported in Claude Code's issue tracker, including a 50GB data loss and a deleted three-year-old Unity project. Hello HN, I built this after a coding agent deleted my files while tidying a project. Do-over plugs into Claude Code's hooks and snapshots what a command is about to touch right before it runs. I know what you're thinking. Why don't you just commit more often? This tool doesn't seek to replace git. What it does is: 1 Protect the stuff git doesn't protect: your untracked/ignored files and files that exist outside your repo which is how a guy lost 50GB of data - Claude code issue tracker 2 Protects you when git itself is weaponized by your agent: git checkout ., git clean -fd, and git reset --hard a three year old Unity project was deleted this way - Claude Code issue tracker 3 Protects you in the case when you're just forgetful and don't commit It really is a simple safeguard to potential headaches. And it's a last mile effort that secures what current measures can't. That includes sandboxes, checkpoints, git. Comments URL: https://news.ycombinator.com/item?id=49371211 https://news.ycombinator.com/item?id=49371211 Points: 1 Comments: 1