Workspace Organization - Automated Health Checks
by @donovanpankratz-del
Automated workspace health checks and entropy prevention for OpenClaw. Detects broken symlinks, empty dirs, large files, malformed names. Maintenance audit s...
Manual Audit
cd ~/.openclaw/workspace/skills/workspace-organization
./maintenance-audit.sh
Example output:
=== Workspace Maintenance Audit ===
Date: 2026-02-21 16:00
Path: /home/user/.openclaw/workspace1. Checking for broken symlinks...
β οΈ Found broken symlinks:
/home/user/.openclaw/workspace/old-project/link-to-deleted
2. Checking for empty directories...
βΉοΈ Found empty directories:
/home/user/.openclaw/workspace/projects/abandoned
3. Checking for large files (>10MB)...
βΉοΈ Found large files:
24M /home/user/.openclaw/workspace/logs/debug.log
4. Checking for malformed file/directory names...
β οΈ Found malformed names:
/home/user/.openclaw/workspace/projects/my project/file.md
5. Disk usage by top-level directory:
150M skills
80M notes
50M projects
30M memory
6. File counts:
Total files: 1,234
Total directories: 156
Skills: 18
Subagents: 3
7. Recently modified files (last 24 hours):
/home/user/.openclaw/workspace/notes/cost-tracking.md
/home/user/.openclaw/workspace/memory/owner/decisions.md
=== Audit Complete ===
Agent-Driven Audit
Ask your agent:
"Run workspace maintenance audit"
"Check workspace health"
"Audit my workspace"
Agent will execute script and present findings with cleanup recommendations.
1. Install skill:
cd ~/.openclaw/workspace/skills
clawhub install workspace-organization
Or: download from ClawHub and extract
2. Initialize workspace (optional, if starting fresh):
cd ~/.openclaw/workspace/skills/workspace-organization
./setup.sh
3. Run first audit:
cd ~/.openclaw/workspace/skills/workspace-organization
./maintenance-audit.sh
4. Schedule automated audits (recommended):
openclaw cron add \
--name "Weekly Workspace Audit" \
--schedule "0 4 * * 0" \
--task "Run workspace maintenance audit: bash skills/workspace-organization/maintenance-audit.sh. Log results to notes/maintenance-log.md"
"Script fails on macOS"
brew install findutilsgfind instead of find"Too many empty directories flagged"
.cache, .venv)"Large files are necessary"
notes/workspace-notes.md why they're keptclawhub install workspace-organization