Manage and delete files efficiently with an interactive TUI and scriptable CLI.
Deletor is a handy file deletion tool that combines a powerful text interface (TUI) with visual directory navigation, and classic command line mode (CLI). With it, you can quickly find and delete files by filters, send them to the trash or completely erase them, as well as clear the cache, both interactively and through scripts.
- π₯οΈ Interactive TUI: Modern text-based user interface for easy file navigation and management
- π±οΈ Mouse Support: Full mouse support for selection, scrolling, and interaction
- π’ Multi-Selection: Select multiple files at once for batch operations
- β»οΈ Safe Deletion: Files: Are moved to the system trash/recycle bin instead of permanent deletion
- π§Ή OS Cache Cleaner: Free up space by deleting temporary system cache
- π οΈ Deep Customization Shape the tool to behave exactly how you need
- π§ Rules System: Save your filter settings and preferences for quick access
- π Log Operations: Log the various fields and look at the tui table, or parse the file
- β³ Modification Time Filter: Delete files older,newer than X days/hours/minutes
- π Size Filter: Deletes only files larger than the specified size
- ποΈ Extensions Filter: Deletes files with specified extensions
- π Directory Navigation: Easy navigation through directories with arrow keys
- π― Quick Selection: Select and delete files with keyboard shortcuts
- β Confirmation Prompt: Optional confirmation before deleting files
go install github.com/pashkov256/deletor@latest
deletor
deletor -cli -d ~/Downloads -e mp4,zip --min-size 10mb -subdirs --exclude data,backup
go run . -cli -d ~/Downloads -e mp4,zip --min-size 10mb -subdirs --exclude data,backup
Flags | Description |
---|---|
-e |
Comma-separated list of extensions (e.g., mp4,zip,jpg ). |
-d |
Path to the file search directory. |
--min-size |
Minimum file size to delete (e.g., 10kb , 1mb , 1gb ). |
--max-size |
Maximum file size to delete (e.g., 10kb , 1mb , 1gb ). |
--older |
Modification time older than (e.g., 1sec , 2min , 3hour , 4day ). |
--newer |
Modification time newer than (e.g., 1sec , 2min , 3hour , 4day ). |
--exclude |
Exclude specific files/paths (e.g., data , backup ). |
-subdirs |
Include subdirectories in scan. Default is false. |
-prune-empty |
Delete empty folders after scan. |
-rules |
Running with values from the rules |
-progress |
Display a progress bar during file scanning. |
-skip-confirm |
Skip the confirmation of deletion. |
-
TUI mode provides a user-friendly way to navigate and manage files visually, ideal for manual cleanups and exploration.
-
CLI mode is perfect for automation, scripting, and quick one-liners. It's essential for server environments, cron jobs, and integrating into larger toolchains.
We welcome and appreciate any contributions to Deletor! There are many ways you can help us grow and improve:
- π Report Bugs β Found an issue? Let us know by opening an issue.
- π‘ Suggest Features β Got an idea for a new feature? We'd love to hear it!
- π Improve Documentation β Help us make the docs even clearer and easier to use.
- π» Submit Code β Fix a bug, refactor code, or add new functionality by submitting a pull request.
Before contributing, please take a moment to read our CONTRIBUTING.md guide. It explains how to set up the project, coding standards, and the process for submitting contributions.
Together, we can make Deletor even better! π
https://code2tutorial.com/tutorial/3aac813f-99c2-453f-819f-c80e4322e068/index.md
This project is distributed under the MIT license.