/loop — manage Claude Code loop cron jobs (Rust-binary backed)
One skill for the whole loop-management family (consolidated from the former
loop-pause / loop-resume / loop-stop / loop-edit / loop-track / loop-update
skills, 2026-06-30). Backed by the claude-loop binary
(~/.local/bin/claude-loop, built by claude-tools install.sh). The binary
owns every shell op (state JSON, history, locking); the agent only makes the
Cron* tool calls. Route on the first argument (the verb):
| Verb | Does | Mechanism |
|---|---|---|
pause |
Pause all active loops; save state for resume | CronList → pipe its JSON to claude-loop pause → CronDelete the returned IDs |
resume [interval] |
Restore paused loops (optional new cadence) | claude-loop resume [--interval <i>] → CronCreate ×N from its JSON-line output |
stop |
Permanently stop a loop (delete cron + clear paused state) | CronList → CronDelete the entry; clear ~/.claude/.paused-loops.json |
edit |
Change interval/prompt without losing the prompt | CronList (full prompt) → CronDelete <old> → CronCreate with the edits |
track <id> |
Register a raw cron into loop history | CronList (verify id) → claude-loop logs a discovered event |
update |
Pull latest claude-tools + reinstall skills/binaries | run ~/projects/claude-tools/update.sh -f; report which commits arrived |
| (none) | Show current loop state | defer to the loops skill (claude-loop list) |
Rules
- Never inline-truncate prompts.
CronListtruncates prompts at ~80 chars; foredit/track/resumeread the full prompt from the binary's state file, not the truncatedCronListview. - Each verb is a thin path — 2–3 visible tool calls (one
Bashto the binary + theCron*calls). Let the binary do the file work. pause/resumeare symmetric (state in~/.claude/.paused-loops.json).stopis terminal — no state kept.- Pipe every loop prompt through
claude-loop prepbeforeCronCreate— it injects the canonical SCHEDULED-LOOP self-check preamble (idempotent), so every fire carries it by construction. - Crash-safety lives in
claude-loop guard/checkpoint/watchdog; seedocs/LOOP_PATTERNS.md.
Don't
- Don't
CronDelete+CronCreatefrom scratch for anedit— that loses the full prompt unless you pulled it first. - Don't append a history event if the
Cron*call failed.