disk-cleanuplisted
Install: claude install-skill wrfcoin/agent-orchestration
# disk-cleanup — Weekly Recovery
A multi-worktree development setup with 7+ named persona worktrees, each
running its own `cargo build`, accumulates disk usage fast. This skill is
the periodic recovery routine — safe by default, runs `--dry-run` unless
explicitly told `--apply`, and never deletes branches with unmerged work.
Cadence: weekly to biweekly, manually invoked. No scheduler.
## What it does
1. **Worktree inventory.** Lists all `worktrees/*-<persona>` directories
under `<workspace>/worktrees/` and their disk usage.
2. **`cargo clean` per worktree.** The biggest space hog in a Rust-heavy
workspace. Each worktree typically holds 2-8 GB of `target/` debug
artifacts.
3. **Merged-branch cleanup.** Lists local + remote branches that have been
merged to `origin/main`. **Never deletes** branches with unmerged
commits. **Never deletes** branches with active worktrees.
4. **Node-side caches.** `npm cache clean --force` and `pnpm store prune`
(only if the relevant tools are installed).
5. **Optional Docker prune.** `docker system prune --volumes` only when
`--include-docker` is passed (this can wipe build caches that take a
long time to rebuild — opt-in only).
6. **WSL VHD shrink prompt.** **Does not** run `Optimize-VHD` directly —
WSL cannot shrink its own backing VHD while running. Instead, prints
the exact PowerShell command to run as Administrator from a Windows
terminal, with the VHDX path resolved.
7. **Reports freed bytes** per step a