ReclaimSpace Docs

A CLI tool to reclaim disk space by finding and removing regeneratable development folders.

It behaves like npx npkill, but goes further by detecting multiple categories of heavy folders/files, providing a navigable grouped CLI, and focusing on modern tech stacks like Shopify and React Router, all without a single runtime dependency.

Usage

Here are some common ways to use reclaimspace:

Interactive Mode (Default)

This is the default behavior. It lists all the folders, and you can select which ones to delete.

npx reclaimspace

Auto-Delete Everything

This will find all reclaimable items and delete them automatically without confirmation.

npx reclaimspace --yes

Dry Run (Preview)

This will list all the items that can be deleted but won't actually delete anything.

npx reclaimspace --dry

Scan a Specific Folder

You can specify one or more directories to scan.

npx reclaimspace <foldername>

Display Version Number

This will display the version number of the tool.

npx reclaimspace --version

Display Help Message

This will display the help message with all available options.

npx reclaimspace --help

Combine Flags and Folders

You can combine any of the flags with a specific folder.

npx reclaimspace --yes my-project

Enable Build Analysis

This will enable build analysis logs.

npx reclaimspace --build-analysis

Ignore Certain Folders Permanently

You can permanently exclude folders from the scan by providing a comma-separated list of patterns. This will update or create a .reclaimspacerc file in the current directory using the --save or -s flag.

npx reclaimspace --ignore "node_modules,dist" --save

Include Only Specific Folders

You can specify a comma-separated list of patterns to include in the scan. When this flag is used, only folders matching these patterns will be considered.

npx reclaimspace --include "my-custom-build,temp-files"

Features

Configuration

You can create a .reclaimspacerc file in the root of your project to specify folders and patterns to ignore.

Example .reclaimspacerc file:

# Ignore all node_modules folders
node_modules

# Ignore a specific build folder
my-project/dist

Detected Items

reclaimspace detects the following categories:

  1. Node Modules
    • node_modules
  2. Build/Cache Folders
    • .next, dist, build, storybook-static, .nuxt, .output, .svelte-kit, .angular, out, .expo, .turbo, .cache, .shopify, .react-router, .tanstack, .vite-ssg-temp
    • .rollup.cache, .parcel-cache, .vite, .astro, .solid, .remix, .docusaurus, .eleventy-cache, .gatsby-cache, .eslintcache, .stylelintcache, .prettiercache, .tsbuildinfo, .swc, .nx, .pnpm-store, .wwebjs_cache, .wwebjs_auth, public/build
  3. Testing/Reporting Folders
    • coverage, .nyc_output, .pytest_cache, .tox, htmlcov
  4. Miscellaneous Dev Junk
    • .venv, venv, env (Python Virtual Environments)
    • __pycache__, .mypy_cache, .ruff_cache (Python caches)
    • vendor (Go/PHP dependencies)
    • .vagrant, .terraform (Infrastructure tools)

Contributing

Contributions are welcome! Please read our contributing guidelines to get started.

Contributors

Contributors