Workspace Cleaner for Openclaw

An automated maintenance utility designed to safely identify and remove temporary files, duplicates, and workspace clutter from your AI environment.

brandonwise
v1.0.0
Feb 15, 2026
0
1.6k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install workspace-cleaner

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install workspace-cleaner using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Workspace Cleaner?

Workspace Cleaner is a robust maintenance utility specifically engineered for users of Openclaw Skills. It streamlines the management of development environments by identifying cruft—temporary downloads, logs, and unnecessary duplicates—while ensuring that critical data like core configurations and git history remains untouched. By providing a safe-by-default approach, it allows developers to maintain a lean and efficient workspace without the risk of accidental data loss.

This utility integrates seamlessly into the Openclaw Skills ecosystem, offering a bridge between manual file management and automated system health. Whether you are running complex agent simulations or managing multiple coding projects, this skill provides the necessary visibility into your disk usage and file lifecycle, making it an essential part of any professional AI development workflow.

Workspace Cleaner Use Cases

  • Automated weekly maintenance to remove stale logs and temporary build files.
  • Identifying large space hogs within your development directories to reclaim disk space.
  • Pre-commit cleanup to ensure no environment-specific clutter is pushed to version control.
  • Recovering storage by targeting files older than a specific date threshold.
  • Integrating periodic workspace health checks via HEARTBEAT configurations in Openclaw Skills.

How Workspace Cleaner Works

  1. The script initializes by loading customizable patterns and protected path definitions from a JSON configuration file.
  2. It scans the designated workspace directory, calculating file sizes and modification ages for all items.
  3. Potential cleanup candidates are filtered against a strict exclusion list to protect critical Openclaw Skills data and active project files.
  4. A preview report is generated in dry-run mode, showing exactly what would be removed and the total space to be reclaimed.
  5. Upon execution, files are moved to the system trash rather than being permanently deleted, allowing for easy recovery if needed.

Workspace Cleaner Setup

To get started with this Openclaw Skills component, ensure you have Python 3.8+ installed along with the system trash utility.

# Install trash utility (macOS)
brew install trash

# Install trash utility (Linux)
sudo apt-get install trash-cli

No additional Python dependencies are required. Navigate to your skill directory and run a preview scan:

# Preview the cleanup without deleting anything
python3 scripts/cleanup.py

Workspace Cleaner Data Schema & Taxonomy

Workspace Cleaner uses a configuration-driven approach to define its logic. The primary data structures involved are:

Component Type Description
patterns.json Configuration Defines temp extensions, protected directories, and known venvs.
scripts/cleanup.py Executable The core logic engine for the Openclaw Skills utility.
JSON Output Schema Machine-readable results containing item paths, sizes in MB, and deletion status.

Protected entities that are never touched include .git/, memory/, and core identity files such as SOUL.md, USER.md, and AGENTS.md.

Workspace Cleaner Advanced Features

  • Custom Pattern Support: Extend the patterns.json file to include proprietary file types or project-specific directories unique to your Openclaw Skills setup.
  • Automation-Ready JSON Output: Pipe cleanup data into tools like jq for advanced reporting, monitoring, or custom automated alerts.
  • Granular Filtering: Use flags like --min-age and --min-size for precise control over which files are targeted for removal.
  • Workspace Targetting: Use the --workspace argument to point the tool at any directory, enabling management of multiple Openclaw Skills environments from one place.
  • Safety-First Recovery: Leverages native OS trash mechanisms instead of destructive rm commands, providing a safety net for all automated actions.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*