Recursos
6Instal·la
npx skillscat add daisuke134/life-manager/life-manager-disk-cleanup Instal·la des del registre de SkillsCat.
Life Manager disk cleanup
This skill owns the local host capacity pass. It is intentionally not a
Life-Manager-directory cleaner: it measures the Mac and only removes an
allow-listed regenerable artifact after an open-path probe confirmsconfirmed-closed.
Safety contract
.claude,.codex,.config/ai, OpenClaw state/identity/workspace,.git,
databases, credentials, cookies, source, andstate/*.jsonlare preserved.- Unknown paths, active leases, symlinks, open paths, and probe errors are
preserved and recorded. sweep()accepts only candidates carrying internal allow-list discovery proof
for the exact regenerable families; the CLI--candidateescape hatch is
rejected so an arbitrary path cannot be promoted by an operator flag.- The 5-minute pass has one atomic lock and no LLM deletion authority.
- Pressure is asserted below 11 GiB and is not cleared until the recovery floor
is reached; the 20 GiB threshold starts preventive containment. - Every pass atomically writes
host-inventory.json: localdfmounts and
bounded owner-family metadata. The hourly/full compatibility pass may run a
timeout-boundedduprobe for allow-listed families; gaps are recorded as
unknown and never become deletion candidates. The fallback adapter keeps a
separatecleanup-full-pass.atmarker so one bounded full cleanup occurs at
most once per hour; a missing or stale marker is fail-closed toward
observation/probe bounds, never toward deleting unknown paths. - The host adapter bounds the governor, runtime-manifest, and sweep subprocesses;
timeout is a preserve/error result and never advances the full-pass marker. - Receipts are bounded and the high-volume cleanup ledger is rotated before it
can consume the reserve.
Local installation
skills/self/disk-cleanup/install-launchd.shThe installer renders the user-specific plist, validates it with plutil, and
registers ai.anicca.life-manager-disk-cleanup at a 300-second interval. If
the macOS launchd user domain is temporarily unavailable, the existing
emergency guard invokes disk_cleanup.py as its single fallback owner. The
legacy hourly label is only a compatibility trigger: the guard'scleanup-full-pass.at marker (or explicit EMERGENCY_GUARD_FULL_PASS=1) opts
into the bounded full pass so deferred worktree inspection is not permanently
skipped.
Run the tests with:
python3 -m pytest -q skills/self/disk-cleanup/tests/test_disk_cleanup.py