Recover a file after accidentally moving or overwriting it with mv or cp.
Restore a deleted directory from the trash after running rm -r.
Browse and undo past shell operations interactively with the built in TUI.
Roll back a batch rename made with the Perl style rename command.
| nvrmnd-png/undo | lucifer1004/veloq | psiini/israeli-alloc | |
|---|---|---|---|
| Stars | 51 | 51 | 51 |
| Language | Rust | Rust | Rust |
| Setup difficulty | easy | moderate | hard |
| Complexity | 2/5 | 4/5 | 5/5 |
| Audience | developer | developer | developer |
Figures from each repo's GitHub metadata at analysis time.
undo is a command line tool written in Rust that gives you a safety net for everyday shell commands like mv, cp, rm, mkdir, rmdir, chmod, chown, ln and rename. Instead of just watching what you type, it intercepts these commands through a small shell integration, performs the operation itself, and records exactly how to reverse it. That means when you accidentally move a file, delete a folder, or overwrite something important, you can type undo and get it back. Deletions do not disappear forever. Files removed with rm or rmdir go to the freedesktop.org trash instead of being erased, and any file that gets overwritten is backed up there first. Before any rollback happens, the tool checks the file's integrity using a BLAKE3 fingerprint, so it refuses to undo something that was changed after the fact unless you explicitly force it. To start using it, you install the binary, either built from source with cargo or downloaded as a prebuilt release, and add one line to your shell startup file for zsh, bash, or fish. After that, your normal mv, cp, and rm commands become undoable without changing how you type them. You can bypass the wrapper for a single command if needed. The tool includes several helper commands: undo lists recent actions, undo history shows the full journal, undo search finds entries by name, and undo tui opens an interactive text based browser for reviewing and undoing entries with the keyboard. Settings such as automatic cleanup, storage location, excluded paths, and custom command aliases live in a configuration file you can edit through a built in editor. There are limits. undo can only reverse operations that went through its own wrappers, so actions run through sudo, scripts, cron jobs, or graphical file managers are not tracked. File permissions like ACLs and extended attributes are not preserved during copies. The project is released under the MIT license, aside from an early version that remains under GPLv3.
A Rust command line tool that lets you undo everyday shell commands like mv, cp, and rm by journaling every operation and reversing it on demand.
Mainly Rust. The stack also includes Rust, SQLite, BLAKE3.
Use freely for any purpose, including commercial use, as long as you keep the copyright notice.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Don't trust strangers blindly. Verify against the repo.