Skip to main content

Module spawn_env

Module spawn_env 

Source
Expand description

The identity variables in an agent’s spawn environment. The server builds the whole environment (server/agent_handlers/input.rs); the process launchers under blockcontroller carry the identity part of it too, so these helpers sit below both.

Modules§

bash_prefix
The Claude agent’s Bash settings at launch: agentmux-bashwrap as the CLI’s CLAUDE_CODE_SHELL_PREFIX, which streams Bash output without the hook rewriting the call (docs/specs/SPEC_BASH_STREAMING_VIA_SHELL_PREFIX_2026_10_10.md).
block_identity
What the spawn environment carries about the agent on a block: the display name and slug, the uid, the workdir.
build
The spawn environment of a persistent-controller CLI process.
endpoint
A Claude Code agent pointed at a server of its own: ANTHROPIC_BASE_URL in its environment names something other than Anthropic (a local model, a LAN server, a proxy; set by an agent through Agents env_set or by the person in My Agents).
former_names
AGENTMUX_AGENT_FORMER_NAMES and AGENTMUX_AGENT_FORMER_SLUGS: the names an agent had before its renames, for gh-agent (0.10+). It signs a PR as the agent that opened it but leaves a title, an Agent: line or a PR-body tag that already names that agent as it is, and it learns the agent’s own names from the environment. Without these two, a renamed agent’s old name (still on a PR it had opened, or in a file it reads) read as another agent’s and was rewritten.
identity
The agent’s identity variables in its spawn environment, beyond what input.rs’s split_agent_identity_env and carry_agent_uid_env set.
run_account
The account a pane’s run launched on, noted on its block at spawn.
workspaces
Which folder each agent on a block was started in, so a browser upload can be checked against it (server/browser_uploads.rs) and the spawn paths can record it without reaching up into the server.