Claude Code 2.1.251 adds detachable background sessions + spend bar
New attach, stop, respawn and rm commands turn backgrounded agents into managed processes — plus /usage spend-limit bar, model-switch hooks, and an Opus 5 fix.

Copy markdown
Backgrounded agents get a process manager
New attach, logs, stop, respawn, and rm subcommands let you reconnect to, tail, halt, restart, or delete a running background session straight from the terminal. Background a run and Claude Code now prints the exact `claude attach <id>` to jump back in.
A spend-limit bar lands in /usage
Developers behind a Claude apps gateway with spend limits now get a live spend bar in /usage and a rate_limits.spend_limit field in the status line — so you can watch, and script against, how close a run is to its budget.
Hooks that fire on model switches
New PreModelSwitch and PostModelSwitch hook events can block, confirm, or annotate a model change. Enough to enforce a rule like 'never silently drop to a cheaper model' in your own automation.
Subagent calls stream to Remote Control
Foreground subagent tool calls now stream live to Remote Control clients, and /cost gains per-session prompt-cache metrics — more visibility into what your parallel agents are actually doing and spending.
The fixes that matter
Opus 5 requests no longer fail at xhigh/max effort when thinking is off; file tools (Read/Write/Edit) can no longer follow symlinks outside approved locations; and the TUI stops lagging under many parallel subagents.