Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add randomittin/heimdall --skill mac-deep-cleangit clone --depth 1 https://github.com/randomittin/heimdallWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/randomittin/heimdall/mac-deep-clean)<a href="https://agentmods.dev/skills/randomittin/heimdall/mac-deep-clean"><img src="https://agentmods.dev/badge/skills/randomittin/heimdall/mac-deep-clean/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/randomittin/heimdall/mac-deep-clean"><img src="https://agentmods.dev/badge/skills/randomittin/heimdall/mac-deep-clean.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00091 | $0.02945 |
| Opus 5.5 | $0.00036 | $0.01178 |
| Sonnet 5.5 | $0.00018 | $0.00589 |
| Haiku 4.5 | $0.00009 | $0.00295 |
Grade D, and why
mac-deep-clean scanned grade D with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Asks for rootmediumPrivilege escalation
A mod that escalates privileges can change anything on the machine, not only the project.
- **`sudo -n true`** to test for cached sudo without prompting; if it fails, print the manual command instead of hanging. Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
find ~/.claude/projects -name '*.jsonl' -mtime +30 -print # list first; append -delete only after the user OKs the list Recursive force deletehighDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
- **Scope precisely.** `rm -rf` explicit paths only. Never `rm -rf` a parent when you mean a child. Verify exact version-dir names (Android SDK, NDK) before deleting "old" versions. How it starts
The opening of the file, as written. The whole thing — 192 lines — stays where its author put it; the contents beside it link to each section on GitHub.
mac-deep-clean
Autonomous macOS storage + memory cleanup. Investigate first (read-only), present a tiered reclaimable map, delete only what's regenerable or user-approved. Destructive ops are irreversible — measure, confirm, then act.
Ships with Heimdall: invoke it as hmd:mac-deep-clean (a copy you installed by hand under ~/.claude/skills/mac-deep-clean/ is plain mac-deep-clean). hmd:system-health and heimdall-cleanup --deep notice the need and hand off here — they never delete anything outside Heimdall's own garbage; this skill is the confirm-gated executor.
Golden rules
- Measure before deleting. Always
du -sh/df -hbefore and after. Report reclaimed bytes. - Irreversible = confirm. Deleting repos/files with uncommitted work needs explicit user naming. Never infer consent from background-task notifications.
- Scope precisely.
rm -rfexplicit paths only. Neverrm -rfa parent when you mean a child. Verify exact version-dir names (Android SDK, NDK) before deleting "old" versions. - Caches regenerate; user data does not. Keep: iMessage db, browser profiles, Notes, VSCode, source
.git, loose documents. Delete: caches, build output, node_modules, old SDK versions, dead worktrees. - Delegate investigation to parallel read-only agents. One agent per domain (repos / user Library / System Data). Spawn concurrently,
run_in_background: true.
macOS gotchas
timeoutdoes not exist on macOS. Userun_in_background: trueor a background&+ poll instead oftimeout N cmd.df -h /lies./is the sealed read-only system snapshot (a small, fixed-size volume). Real data lives on/System/Volumes/Data. Usediskutil info /→ "Container Free Space" for true free.- "System Data" bucket = swap + Preboot + caches + logs + diagnostics + purgeable. Not a folder — an aggregate.
ps auxRSS undercounts (shared/compressed pages). For real memory usetop -l 1 -o memandvm_stat. Numbers invm_statend in.— strip withsed 's/\.//'before math.sudo -n trueto test for cached sudo without prompting; if it fails, print the manual command instead of hanging.pnpm store prune/go clean -cachecan hang — preferrm -rf ~/Library/Caches/{pnpm,go-build}directly.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 192 lines · 91 tokens per session scan D 6059421301c6
mac-deep-clean is a skill published in the GitHub repository randomittin/heimdall (5 stars, last pushed yesterday), licensed MIT. It adds 91 tokens to every session and 2,945 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it D with 3 findings (asks for root, reads agent configuration directories, recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-09.
mac-deep-clean compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| mac-deep-cleanrandomittin/heimdall | Skill | 5 | yesterday | MIT | D | 91 | Claude Code |
| systemic-issue-triageGentleman-Programming/gentle-ai | Skill | 9.8k | yesterday | MIT | A | 57 | Claude Code, Codex |
| issue-root-resolutionGentleman-Programming/gentle-ai | Skill | 9.8k | yesterday | MIT | A | 45 | Claude Code, Codex |
| rdd-defect-workflowGentleman-Programming/gentle-ai | Skill | 9.8k | yesterday | MIT | A | 38 | Claude Code, Codex |
| autofixQwenLM/qwen-code | Skill | 31k | today | Apache-2.0 | C | 30 | Claude Code |
| aoe-runtime-lifecycleagent-of-empires/agent-of-empires | Skill | 5.3k | today | MIT | A | 76 | Claude Code, Codex |
| review-difffaizkhairi/claude-code-blueprint | Skill | 74 | 20d ago | MIT | A | 40 | Claude Code |