/arc:prune-agents
Kill orphaned agents
—What it does
Prune-agents finds and kills Claude Code processes that have become orphaned — detached from their terminal (TTY shows "??"). These accumulate when the Task tool spawns subagents that don't cleanly exit after completion.
—Why it exists
Orphaned Claude processes consume memory and CPU in the background. Pruning periodically keeps your system clean without affecting active terminal sessions.
Source document
<arc_runtime> Arc-owned files live under the Arc install root for full-runtime installs.
Set ${ARC_ROOT} to that root and use ${ARC_ROOT}/... for Arc bundle files such as
references/, disciplines/, agents/, templates/, scripts/, and rules/.
Project-local files stay relative to the user's repository. </arc_runtime>
Prune Orphaned Agents
Run the cleanup script to kill orphaned Claude agent processes.
${ARC_ROOT}/scripts/cleanup-orphaned-agents.sh
This kills Claude Code processes that have become detached from their terminal (TTY shows "??"). These accumulate when the Task tool spawns subagents that don't cleanly exit after completion.
Safe to run anytime — only kills orphaned processes. Active terminal sessions are preserved.
After running, report the result to the user including how many processes were cleaned up.