Ctrl+Z
for your terminal.

Every interface has undo except the terminal — where you can do the most damage. oops fixes that.

$ curl -fsSL oops-cli.com/install.sh | bash

The installer handles everything — downloads the binary, adds the shell hook, and sets up the backup directory. Just answer y/n.

~ $ rm -rf src/
▲ rm -r ~/project/src

~ $ oops
✓ Undid: rm -r ~/project/src
↩ restored ~/project/src

What it catches

oops intercepts destructive commands before they run and silently backs up the affected files. Non-destructive commands pass through with zero overhead.

CommandWhat oops doesUndo
rm / rm -rfCopies files to trash before deletionrestore
mv a bBacks up the overwrite targetrestore b
> file.txtSnapshots file before redirect overwrites itrestore
sed -iCopies file before in-place editrestore
chmod / chownRecords original permissionsrestore
git reset --hardCreates a stash before resetstash apply
git checkout .Creates a stashstash apply
git branch -DLogs the branch SHA before deletionrecreate
git clean -fdStashes untracked filesstash apply

Install

One command. The installer walks you through each step with y/n prompts — binary, shell hook, and backup directory.

curl -fsSL oops-cli.com/install.sh | bash

CLI reference

CommandDescription
oopsUndo the last destructive action
oops 2Undo the second-to-last action
oops logShow undo history
oops sizeShow backup disk usage
oops cleanRemove old backups (--all for everything)
oops configView or change settings
oops doctorCheck installation health
oops uninstallRemove oops from your system

Type oops. Get your files back.

Single binary, written in Go, no dependencies. ~10ms backup overhead. Auto-cleanup after 7 days. Read the docs.

$ curl -fsSL oops-cli.com/install.sh | bash