Skip to content

paperalt/goclean

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go Linux Cleaner

A safe, performant, and feature-rich Linux system cleaner written in Go. featuring a modern TUI (Text User Interface) and a scriptable CLI mode.

Goclean TUI Screenshot

Features

  • Interactive TUI: Visual dashboard to select and run cleaners.
  • APT Cache: Cleans /var/cache/apt/archives.
  • System Logs: Vacuums journald and removes old log files.
  • Trash: Empties user trash (~/.local/share/Trash).
  • Caches:
    • Thumbnails (~/.cache/thumbnails)
    • Browsers (Chrome, Firefox, Brave, etc.)
    • Go Build Cache
    • Generic Cache Scanner
  • Docker: Prunes unused system objects.
  • Large Files: Interactive scanner for old (>30 days), large (>100MB) files.

Installation

git clone https://github.com/paperalt/goclean.git
cd goclean
go build -ldflags "-s -w" -o goclean ./cmd/goclean

Usage

Interactive TUI (Default)

Simply run the binary to launch the TUI:

./goclean
  • Use Up/Down keys to navigate.
  • Use Space to toggle selection.
  • Press Enter to clean selected items.

CLI Mode (Scriptable)

Use --no-tui for standard command-line output.

# Dry run (simulate without deleting)
./goclean --no-tui --dry-run

# Run non-interactively (skip confirmations)
sudo ./goclean --no-tui --yes

Note: Some cleaners (APT, Docker, Logs) may require sudo privileges.

Safety

  • Dry Run: Always verify with --dry-run first.
  • Confirmations: The tool asks for confirmation before deleting large files or running mass cleanups (unless --yes is used).
  • Exclusions: Hidden folders are skipped during large file scans to protect config files.

License

MIT

About

Linux system cleaner to freeup space build with Golang for performance

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages