The tmux display-message approach had edge cases: it could succeed outside tmux, fail on first iteration, or behave differently depending on tmux socket state. Replace with AGENT_LOOP_ACTIVE env var exported by loop.sh. CC sessions spawned by the loop inherit it; interactive CC sessions don't. Simple, no external dependencies, no race conditions.
382 B
382 B