workspace-cleanerAutomates safe cleanup of OpenClaw workspaces by previewing and moving temp files, logs, duplicates, and cruft to the system trash with customizable filtering.
Install via ClawdBot CLI:
clawdbot install brandonwise/workspace-cleanerSafe, automated cleanup for OpenClaw workspaces. Finds temp files, duplicates, and cruft while protecting important data.
# Preview what would be deleted (safe - no changes)
python3 {{SKILL_DIR}}/scripts/cleanup.py
# Actually clean up (uses trash for recovery)
python3 {{SKILL_DIR}}/scripts/cleanup.py --execute
# Custom workspace path
python3 {{SKILL_DIR}}/scripts/cleanup.py --workspace /path/to/workspace
python3 {{SKILL_DIR}}/scripts/cleanup.py
Shows what would be deleted with sizes. Makes no changes.
python3 {{SKILL_DIR}}/scripts/cleanup.py --execute
Moves items to trash. Recoverable via system trash.
# Only show items larger than 100MB
python3 {{SKILL_DIR}}/scripts/cleanup.py --min-size 100
# Only show items older than 30 days
python3 {{SKILL_DIR}}/scripts/cleanup.py --min-age 30
# For automation/parsing
python3 {{SKILL_DIR}}/scripts/cleanup.py --json
# Use custom patterns file
python3 {{SKILL_DIR}}/scripts/cleanup.py --config /path/to/patterns.json
Default patterns (customizable via config):
| Category | Patterns | Safe? |
|----------|----------|-------|
| Temp downloads | *.skill in root | โ
|
| Generated images | .png, .jpg in root | โ
|
| macOS cruft | .DS_Store | โ
|
| Logs | *.log | โ
|
| Temp files | .tmp, .bak, *~ | โ
|
| Node modules | node_modules/ in root | โ
|
| Python venvs | .venv*/, venv/ (except known) | โ ๏ธ |
| Duplicate repos | Same remote as projects/* | โ ๏ธ |
Never deleted, regardless of patterns:
.git/ directoriesmemory/ directoryMEMORY.md, SOUL.md, USER.md, AGENTS.mdprojects/ directory contentsskills/ directory contents--include-recent)Edit {{SKILL_DIR}}/config/patterns.json to customize:
{
"temp_extensions": [".tmp", ".bak", ".log", ".skill"],
"temp_patterns": ["*~", "#*#"],
"image_extensions": [".png", ".jpg", ".jpeg", ".gif"],
"protected_dirs": ["memory", "skills", "projects", ".git"],
"protected_files": ["MEMORY.md", "SOUL.md", "USER.md", "AGENTS.md"],
"known_venvs": [".venv-skill-scanner"]
}
Add to your HEARTBEAT.md for periodic cleanup checks:
## Weekly Cleanup Check
- Run workspace cleaner in preview mode
- Alert if >500MB of cruft found
- Auto-clean items >30 days old and <10MB
--execute to see what would be deleted--exclude for files that look like cruft but aren't# Weekly cleanup of obvious cruft
python3 {{SKILL_DIR}}/scripts/cleanup.py --min-age 7 --execute
# What's taking up space?
python3 {{SKILL_DIR}}/scripts/cleanup.py --min-size 50 --json | jq '.items | sort_by(.size_mb) | reverse'
# Clean before committing
python3 {{SKILL_DIR}}/scripts/cleanup.py --execute && git status
trash command (macOS: brew install trash, Linux: trash-cli)Generated Mar 1, 2026
A development team uses the Workspace Cleaner to automatically remove temporary build artifacts, logs, and duplicate repositories from their shared project directories. This ensures a clean working environment, reduces storage costs, and prevents accidental deletions of important files like .git directories or recent changes.
Data scientists employ the skill to filter out large, old generated image files and temporary data files from their workspaces. By using size and age thresholds, they can free up significant storage space while protecting critical datasets and configuration files, streamlining project management.
A creative agency integrates the Workspace Cleaner into their workflow to periodically delete obsolete design drafts and temporary files from shared drives. The dry-run feature allows for safe previews, and trash recovery provides a safety net, ensuring no important client assets are lost.
IT administrators use the skill to clean up user workspaces across an organization, targeting macOS cruft like .DS_Store files and old logs. This improves system performance, reduces backup sizes, and can be automated with JSON output for reporting and compliance checks.
Offer a basic version of the Workspace Cleaner for free with limited features, such as basic pattern matching. Charge for advanced capabilities like custom automation, enterprise-level integrations, and priority support, targeting teams and organizations.
Sell annual licenses to large companies for deploying the Workspace Cleaner across their entire infrastructure. Include features like centralized configuration management, audit logs, and dedicated support, focusing on scalability and security.
Provide consulting services to tailor the Workspace Cleaner for specific industry needs, such as integrating with existing CI/CD pipelines or developing custom patterns. Offer training and ongoing maintenance contracts to ensure optimal usage.
๐ฌ Integration Tip
Integrate the Workspace Cleaner into automated scripts or CI/CD pipelines using the JSON output option for parsing results and triggering actions based on cleanup metrics.
Home improvement, maintenance, and living space optimization with practical guidance.
ๆไพไธฅๆ ผๆไผๅ ็บงๆญฅ้ชค่ฏๆญไธ่งฃๅณ็ณป็ปใ่ฝฏไปถใ้ ็ฝฎๅๆฅ้้ฎ้ข๏ผ็ปๅ่ฎฐๅฟๅน้ ใๅฎๆนๆๆกฃๅๅคๆฅๆบ้ช่ฏ็กฎไฟๆนๆก้ซๆๅฏ้ ใ
Maintain workspace documentation hygiene and discoverability. Use when organizing markdown sprawl, updating doc indexes, archiving stale progress/status snap...
Book it-support services through Lokuli MCP. Use when user needs to find and book it-support. Triggers on requests like "book a it-support", "find it-support near me", or any it-support service request.
Performs Neill-authorized emergency repair on Billy system authentication by clearing tokens, restarting gateway, backing up config, and verifying success.
Manage and track your plants and garden with care schedules, growth monitoring, and detailed records for watering, fertilizing, pruning, harvesting, and more.