Skip to content

Navigation Menu

Sign in
Sign up

Latest commit

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

MacClean

MacClean

On-device antivirus + junk/cleanup toolkit for macOS. One command, no telemetry, nothing leaves your Mac.

MacClean bundles two small shell scripts:

  • macclean — a CleanMyMac-style cleaner: user/system cache & log junk, dev-tool caches (Xcode, Homebrew, npm, pip, gradle, docker...), a disk-space analyzer, and an app uninstaller that also removes leftovers. Dry-run by default — nothing is deleted without --apply.
  • avscan — a ClamAV wrapper for on-demand malware scanning. Also reachable as macclean scan.

Install

git clone https://github.com/RouterGlock/MacClean.git
cd MacClean
./install.sh # copies macclean + avscan into ~/.local/bin, fixes PATH
./install.sh --with-av # ...and installs ClamAV via Homebrew + fetches signatures

Open a new shell afterwards so ~/.local/bin is on your PATH.

Usage

Command What it does
macclean checkup [-u] Read-only overview: AV quick-scan of ~/Downloads + junk + dev + disk-space previews. Deletes nothing. -u refreshes ClamAV signatures first.
macclean junk [--apply] [--deep] Caches, logs, Trash, saved app state, Mail downloads. --deep adds sandboxed container caches.
macclean dev [--apply] [--deep] Xcode/SwiftPM/simulator caches; brew/npm/yarn/pip/CocoaPods/gradle/go caches; on --apply also runs brew cleanup, simctl delete unavailable, docker system prune.
macclean all [--apply] [--deep] junk + dev.
macclean space [--path DIR] [--top N] [--days N] [--dupes] Report only. Largest folders/files, old Downloads, iOS backups, optional duplicate scan.
macclean uninstall <App|/path/App.app> [--apply] Finds the app + its ~/Library leftovers by name & bundle id; prints sudo rm lines for system-level items.
macclean scan [-u] [-q] [-a] [-v] [PATH...] ClamAV scan (delegates to avscan). -u update signatures first, -q quarantine, -a no size caps.

Safety model

  • Dry-run is the default. Every destructive subcommand previews paths + sizes and exits without touching anything.
  • --apply performs a hard rm -rf. --yes skips the confirmation prompt.
  • space has no --apply — it never deletes.
  • junk/dev refuse to run as root, and the internal delete list hard-refuses /, $HOME, ~/Library, ~/Documents, ~/Desktop.
  • junk / dev / all / uninstall runs are logged to ~/.local/var/log/macclean/<sub>-<timestamp>.log; avscan logs to ~/.local/var/log/avscan/.

The app

MacClean app icon

Download MacClean.app.zip from the latest release. Unzip, then double-click MacClean.app — pick Checkup / Junk / Dev caches / Scan Downloads (or the — APPLY variants) from a menu; the run opens in Terminal.

The app is unsigned, so the first launch is right-click → Open (or xattr -dr com.apple.quarantine MacClean.app). It just calls the macclean you installed above.

Build it yourself: app/build-app.sh.

Weekly checkup (optional)

./scripts/install-schedule.sh

Installs a launchd agent (com.routerglock.macclean.checkup) that runs macclean checkup --update every Sunday at 10:00 (refreshes ClamAV signatures, then the read-only checkup), appending to ~/.local/var/log/macclean/checkup.log. Remove with ./scripts/install-schedule.sh --uninstall.

License

MIT © 2026 RouterGlock

About

On-device antivirus + junk/cleanup toolkit for macOS — ClamAV scanner and a CleanMyMac-style cleaner in one CLI, plus a menu app.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /