Lightweight Disk Space & Comprehensive Dependency Optimizer for Linux & macOS Systems Created by monx.one
SpaceGuard is an intelligent, low-footprint system utility designed specifically for Debian, Kali Linux, Ubuntu, and macOS environments. Built on a strict "Monitor Everything" policy, SpaceGuard captures and categorizes 100% of data occupying disk storage — including system packages (apt/brew), custom binary downloads (wget/curl), Docker & Podman container layers, system caches, user trash bins, and external USB ingests.
- Folder & Application Modes: Switch seamlessly between directory hierarchy breakdown (
/usr,/var,/home,/opt,~/Library,/tmp) and granular application/download tiles. - Hover & Metrics Summary: View exact disk footprint (MB/GB), percentage of used storage, path location, first discovered date, and last access date on hover.
- Contextual Actions: Right-click any tile to copy paths, inspect dependencies in the D3 graph, quick-clean/purge resources, or add items to the protected safeguard exclude list.
- Factual Disk State Audit: Scans system packages (
dpkg/brew),/var/cache/apt/archives,~/Library/Caches, user Trash bins, custom downloads, and USB ingests. - Container Runtime Scrapers: Detects dangling Docker, Podman & OrbStack overlay images (
/var/lib/docker/overlay2,~/.orbstack), exited containers, and unused pods. - Zero-Wait Ingestion: Immediately indexes pre-existing tools and downloads on filled disks without waiting for background event triggers.
- Shared Library Linkage Visualization: Displays real-time relationships between installed software and shared libraries (
libc6,libssl3,.so/.dylib). - Impact Simulation: Visualizes cascading dependency removals before executing destructive commands.
- Dedicated macOS Suite: Includes Homebrew Formula (
macos/Formula/spaceguard.rb), automated installer (macos/install.sh), and Applelaunchddaemon agent (com.monx.spaceguard.daemon.plist). - Native macOS Targets: Cleans Xcode DerivedData, Homebrew caches, and APFS user trash. Detailed guide available at
docs/MACOS_INSTALLATION.md.
Live tracking of system disk space, installed packages, and deep origin tracking for manually downloaded binaries (wget/curl).
Hierarchical treemap breakdown of space-heavy directories (/var/lib/docker, /usr/share, /home/kali, /var/cache).
Visual link analyzer showing library cross-dependencies and simulating cascading removals prior to executing commands.
Real-time container engine inspection, identifying writable layer bloat, stopped pods, and dangling images.
Embedded terminal console allowing direct control over the background SpaceGuard RPC daemon socket.
Download the pre-compiled .deb package directly from the repo:
# Download the package
wget https://github.com/MutantMonx/SpaceGuard/raw/main/pkg/spaceguard_1.2.0_amd64.deb
# Install via dpkg
sudo dpkg -i spaceguard_1.2.0_amd64.deb
# Resolve any missing dependencies automatically
sudo apt-get install -f# Add SpaceGuard repository key and source
echo "deb [trusted=yes] https://raw.githubusercontent.com/MutantMonx/SpaceGuard/main/pkg/ ./" | sudo tee /etc/apt/sources.list.d/spaceguard.list
# Update APT package indexes & install
sudo apt update
sudo apt install spaceguard# Tap and install via Homebrew
brew tap mutantmonx/spaceguard https://github.com/MutantMonx/SpaceGuard
brew install spaceguard
# Start launchd service
brew services start spaceguardcurl -fsSL https://raw.githubusercontent.com/MutantMonx/SpaceGuard/main/macos/install.sh | bash📖 Full macOS documentation: See
docs/MACOS_INSTALLATION.mdfor launchd configuration, Xcode cache purge commands, and Homebrew integration.
Ensure Node.js (v18+) is installed on your system:
# Clone the repository
git clone https://github.com/MutantMonx/SpaceGuard.git
cd SpaceGuard
# Install dependencies & start dev mode
npm install
npm run devTo build for production:
npm run build
npm startSpaceGuard includes a command-line interface mimicking the daemon socket RPC:
| Command | Description |
|---|---|
spaceguard open |
Otwiera gotowy interfejs graficzny SpaceGuard w domyślnej przeglądarce. |
spaceguard status |
Display disk usage breakdown, daemon health, and memory footprint. |
spaceguard scan |
Run a deep diagnostic scan across system packages, containers, and trash. |
spaceguard clean |
Flush APT / Homebrew package cache and user trash bins. |
spaceguard clean-mac |
(macOS only) Purge Homebrew cache, Xcode DerivedData, and ~/.Trash. |
spaceguard autoremove |
Purge orphaned packages and unlinked shared libraries. |
spaceguard containers prune |
Remove dangling Docker/Podman/OrbStack images and stopped containers. |
spaceguard --help |
Wyświetla pełny przewodnik po poleceniach konsolowych CLI. |
SpaceGuard został zaprojektowany z myślą o natychmiastowym działaniu Out-of-the-Box:
- Brak Konfliktów Portowych (Resilient Port Fallback): Jeśli Twój system posiada już inną usługę działającą na porcie
3000, demon SpaceGuard wykryje błądEADDRINUSE, po czym bezkolizyjnie przeskoczy na najbliższy wolny port (np.3001,3002lub przydzielony dynamicznie przez OS), zapisując aktualny adres w pliku/tmp/spaceguard.port. - Dedykowany Skrót w Menu Aplikacji (Desktop Entry): Po zainstalowaniu pakietu
.deb, w menu Twojego środowiska (GNOME, KDE, XFCE, Kali Menu) pojawi się gotowa ikona SpaceGuard. Kliknięcie jej automatycznie uruchomi poleceniespaceguard open. - System Tray AppIndicator: Wbudowany wskaźnik żywego stanu dysku oraz ikona tray pozwala na błyskawiczne wywoływanie czyszczenia oraz monitorowanie zasobów w czasie rzeczywistym.
Run the build script directly or via API endpoint:
bash build-deb.shOutput: pkg/spaceguard_1.2.0_amd64.deb
macos/
├── Formula/spaceguard.rb # Homebrew Formula
├── com.monx.spaceguard.daemon.plist # Apple launchd service plist
├── install.sh # Automated 1-step installer
└── uninstall.sh # Automated uninstaller
Distributed under the Apache License 2.0. See LICENSE for details.
Contributions, bug reports, and feature requests are welcome! Feel free to check the issues page.
Developed with ❤️ for Debian, Kali Linux, Ubuntu & macOS power users.