cd /news/ai-tools/show-hn-do-over-undo-for-ai-agent-sh… · home topics ai-tools article
[ARTICLE · art-104092] src=github.com ↗ pub= topic=ai-tools verified=true sentiment=· neutral

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.

read1 min views3 publishedAug 20, 2026

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

── more in #ai-tools 4 stories · sorted by recency
── more on @do-over 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/show-hn-do-over-undo…] indexed:0 read:1min 2026-08-20 ·