This minimal MVP provides three main pieces:
agent-sidebar.tmuxtmux-agent
makeThis produces:
./bin/tmux-agentThe existing build script still works:
./scripts/build.shmake installBy default this installs:
/usr/local/bin/tmux-agent
/usr/local/share/tmux-agent/agent-sidebar.tmuxYou can override the install prefix if needed:
make install PREFIX="$HOME/.local"Add this to ~/.tmux.conf:
source-file /usr/local/share/tmux-agent/agent-sidebar.tmuxThen reload your tmux config:
tmux source-file ~/.tmux.confDefault key binding:
prefix + A: open or close the right sidebarprefix + N: switch between the current normal window and its correspondingagentwindow; if the target side does not exist, create it in the same directory and register the agent window in the sidebar
The tmux plugin defaults @agent-sidebar-bin to tmux-agent, so make sure the installed binary is in your PATH, or override it in ~/.tmux.conf:
set -g @agent-sidebar-bin "/absolute/path/to/bin/tmux-agent"The plugin also installs tmux hooks so that:
- opening the sidebar immediately focuses it
- moving focus away from the sidebar automatically closes it
This behavior is implemented with tmux focus-events and the pane-focus-out hook, which calls tmux-agent close --pane-id #{hook_pane}.
The plugin also prepends a single aggregated agent slot to status-right:
A:0: no agent windowsA:3: three active agent windowsA:2?: at least one agent is waiting for inputA:1!: at least one agent is in error
If needed, you can override the dedicated agent session name:
set -g @agent-sidebar-agent-session-name "__agent__"For the dedicated __agent__ session, tmux-agent also sets:
set -t __agent__ detach-on-destroy offso when that session is destroyed, tmux switches the client back to the most recently active remaining session. This only applies to the agent session, not globally to every tmux session.
Run this inside a tmux pane:
export TMUX_AGENT_RUNTIME_KEY="codex-$(date +%s)-$$"
./bin/tmux-agent prepare \
--source codex \
--runtime-key "$TMUX_AGENT_RUNTIME_KEY" \
--title "new codex window"
./bin/tmux-agent start \
--source codex \
--runtime-key "$TMUX_AGENT_RUNTIME_KEY" \
--title "demo codex task" \
--status runningThen run:
./bin/tmux-agent update \
--runtime-key "$TMUX_AGENT_RUNTIME_KEY" \
--status waiting_input \
--title "waiting for review"prepare can be called as soon as a new tmux window is created so the pane is immediately classified as an agent pane in the sidebar. start then promotes the same runtime to running when the real agent process begins.
The sidebar will show the state in the Agents section.
Example scripts live in:
examples/hooks/codex/examples/hooks/claude/
These scripts call the shared tmux-agent binary and write state into tmux pane options and runtime JSON.
This is still a minimal MVP:
- It supports a right sidebar
- It shows both agent items and normal sessions
- It supports
CodexandClaudeas sources - Hook config files still need to be wired into your local CLI setup
Not implemented yet:
- Rich detail views
- Fine-grained hook payload parsing
- TPM auto-install support