npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@shoaaib_taimur/clrx

v1.0.5

Published

Safe, modern macOS storage cleaner CLI

Readme

ClrX

npm version npm downloads GitHub Platform Node.js License: MIT

Safe, interactive macOS storage cleaner built with TypeScript.

Analyze first. Explain what can be removed. Ask before destructive operations. Never blindly delete user data.

ClrX safely reclaims gigabytes of disk space by targeting system caches, user logs, browser data, package manager stores, developer tool artifacts, and trash — with zero guesswork and strict guardrails.


Installation

Install globally from npm:

npm install -g @shoaaib_taimur/clrx

Or run directly without installing:

npx @shoaaib_taimur/clrx

Requirements: macOS 12 (Monterey) or later. Node.js ≥ 20. Apple Silicon and Intel supported.


Key Features

  • Interactive Dashboard — Real-time storage breakdown by category with arrow-key navigation.
  • SIP & TCC Compatibility — Uses native macOS Finder AppleScript for Trash inspection and emptying; handles system-protected cache directories without crashing.
  • Safe by Default — Every destructive action requires explicit confirmation.
  • Dry-Run Mode — Preview exact file paths and byte counts before anything is touched (--dry-run).
  • Protected Paths — Documents, Desktop, Photos, Keychain, SSH keys, and system directories are permanently hardlocked against deletion.
  • Developer Tool Cleaners — Targets npm, pnpm, Yarn, CocoaPods, Homebrew, Xcode DerivedData, Simulator caches, and Docker dangling images.
  • Smooth Navigation — Constrained arrow-key browsing (loop: false) with explicit on-screen cancel and exit options (no forced Ctrl+C).
  • Update Notifications — Checks npm registry in background on launch with quick one-click upgrade.
  • Machine-Readable Output — Full JSON support (clrx scan --json) for automated workflows.
  • Zero Sudo Required — Runs entirely as your standard user.

Safety Philosophy

ClrX enforces a strict safety model:

  1. Analyze First — Scans and reports reclaimable size before asking to delete.
  2. Explicit Consent — All destructive operations require confirmation.
  3. Protected Paths — These are never deleted under any circumstances:
    • ~/Documents, ~/Desktop, ~/Pictures, ~/Movies, ~/Music
    • ~/.ssh, ~/.gnupg, ~/.aws
    • ~/Library/Keychains, ~/Library/Preferences
    • /System, /Library, /, /usr, /bin
  4. Path Validation — All paths are resolved and checked against path traversal attacks.
  5. Safe APIs — Uses native Node.js filesystem APIs with recursive safety checks instead of dangerous shell commands like rm -rf ${userInput}.
  6. Report-Only for Sensitive Folders:
    • ~/Downloads is analyzed and reported for manual review, never auto-deleted.
    • iOS / iPad Backups are detected and reported for management via Finder / iTunes.
    • Docker volumes are never pruned — only dangling images and stopped containers.

Usage

Interactive Dashboard

clrx

Launches the interactive dashboard showing current reclaimable storage overview, scan options, safe cleaner, dry run, and system info.

Scan Reclaimable Space

# Scan all categories
clrx scan

# Scan and output JSON
clrx scan --json

# Scan a single category
clrx scan --category user-caches
clrx scan --category npm-cache

Clean Reclaimable Space

# Interactive selection (choose categories with Space, confirm with Enter)
clrx clean

# Dry-run preview (shows exactly what would be removed — nothing is deleted)
clrx clean --dry-run

# Clean only SAFE-rated categories
clrx clean --safe

# Auto-confirm safe categories (for scripts / cron)
clrx clean --safe --yes

# Clean a specific category
clrx clean --category homebrew

# Verbose logging
clrx clean --verbose

System & Disk Info

clrx info

Displays macOS version, architecture, Node.js version, disk partition usage, detected developer tools (npm, brew, docker, xcode, pod), and category breakdown.


Cleanup Categories

| Category | Safety Level | Target Paths | |---|---|---| | User Caches | SAFE | ~/Library/Caches | | User Logs | SAFE | ~/Library/Logs | | Browser Caches | SAFE | Google Chrome, Firefox, Safari cache stores | | npm Cache | SAFE | ~/.npm | | pnpm Cache | SAFE | ~/Library/pnpm/store | | Yarn Cache | SAFE | ~/Library/Caches/Yarn | | CocoaPods Cache | SAFE | ~/Library/Caches/CocoaPods | | Homebrew | CAUTION | Homebrew cache + brew cleanup prune | | Xcode | CAUTION | ~/Library/Developer/Xcode/DerivedData + iOS Simulator caches | | Docker | CAUTION | Dangling images and stopped containers | | Trash | CAUTION | ~/.Trash and mounted volume trash via Finder | | Downloads | CONFIRMATION REQUIRED | ~/Downloads (Report-only, manual review) | | iOS Backups | CONFIRMATION REQUIRED | ~/Library/Application Support/MobileSync/Backup (Report-only) |


Development

# Clone and install dependencies
git clone https://github.com/ShoaaibTaimur/clrx-cli.git
cd clrx-cli
npm install

# Run in dev mode (hot execution with tsx)
npm run dev

# Run test suite (77 tests across safety, cleaners, dryrun, registry)
npm test

# Build TypeScript to dist/
npm run build

# Code style and linting
npm run lint
npm run format
npm run typecheck

Links


License

MIT © Shoaaib Taimur