Macos storage audit
Skill percymcn/agent-cookbook/skills/devops/macos-storage-audit
Audit and triage disk usage on Purse's macOS agents without deleting anything prematurely.From its SKILL.md
npx -y skills add percymcn/agent-cookbook --skill macos-storage-auditAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
4.0 KB, 973 tokens by cl100k_base, as published. Nobody here has run it
macOS Storage Audit
Use this when Purse asks what is taking up storage, whether the Mac is low on disk, or what can be safely cleaned. The goal is to report real evidence first, then propose cleanup tiers. Do not delete data unless Purse explicitly asks for cleanup.
Workflow
-
Check real capacity first
df -h / df -h diskutil apfs list diskutil info /On APFS, the root
/volume can look smaller than the Data volume. Pay attention to the APFS container total, Data volume usage, and free space. -
Check snapshots
tmutil listlocalsnapshots /Local snapshots can consume space, but do not assume they exist.
-
Find top consumers with bounded scans Full
duscans can hang on macOS because of permission-protected folders and huge trees. Prefer targeted and timeout-bounded checks:du -sh /Users/pharma6/.cache /Users/pharma6/.npm /Users/pharma6/.ollama /Users/pharma6/.colima 2>/dev/null du -sh "/Users/pharma6/Library/Application Support"/* 2>/dev/null | sort -h | tail -30 du -sh /Users/pharma6/* /Users/pharma6/.[!.]* 2>/dev/null | sort -h | tail -50If a broad scan times out, continue with narrower directories instead of waiting indefinitely.
-
Distinguish apparent vs allocated size Sparse VM files can look enormous but not consume that much physical disk. For Docker/VM images, inspect allocated blocks:
python3 - <<'PY' import os p='/Users/pharma6/Library/Containers/com.docker.docker/Data/vms/0/data/Docker.raw' st=os.stat(p) print(f'apparent={st.st_size/1024/1024/1024:.2f} GB') print(f'allocated={st.st_blocks*512/1024/1024/1024:.2f} GB') PYDo not call a sparse
Docker.rawthe main culprit unless allocated size is also high. -
Check container/model stores Common large directories on Purse's Mac agents:
- Colima/Lima:
/Users/pharma6/.colima/_lima, especially_disks - Ollama models:
/Users/pharma6/.ollama/models/blobs - HuggingFace cache:
/Users/pharma6/.cache/huggingface - uv cache:
/Users/pharma6/.cache/uv - npm npx cache:
/Users/pharma6/.npm/_npx - Claude app VM bundles:
/Users/pharma6/Library/Application Support/Claude/vm_bundles - oversized logs, e.g. project
logs/*.log
- Colima/Lima:
-
Report cleanup tiers
- Safe/low risk: package caches, npx cache, old logs, temporary browser screenshots.
- Medium risk: model caches (HuggingFace/Ollama) if local models are not needed immediately.
- High impact but verify first: Colima/Lima VM disks, Docker data, Claude VM bundles, GitHub runners/workspaces.
-
When Purse explicitly says something “has to go,” execute deletion and verify Treat direct language like “Colima and Ollama gotta go” as deletion approval for those named targets. Stop relevant services/processes first, remove the named storage roots, then verify free space and path absence before reporting. See
references/container-model-store-cleanup.mdfor the Colima/Ollama pattern and concise reporting shape.
Reporting style
Purse prefers concise, action-oriented results:
- Lead with free space and urgency.
- List top storage consumers with sizes and paths.
- Separate “safe cleanup now” from “needs approval/verification.”
- Avoid long raw dumps; keep evidence in bullets.
- If recommending deletion, state expected reclaimed GB and risk.
Guardrails
- Never delete, prune Docker/Colima, remove models, or truncate logs without explicit cleanup approval.
- Before deleting container/VM data, check whether Docker/Colima processes are running and whether active projects depend on them.
- Before removing models, list model names/blobs where possible and ask if local inference is still needed.
- Do not treat
command not found, permission errors, or timeout from a broad scan as durable facts; switch to a narrower scan.
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.