README
¶
sessui
A tmux session switcher in a popup. Shows what every session is doing — local and on your other machines — and gets out of the way.

Install
TPM — add to ~/.config/tmux/tmux.conf, then prefix + I:
set -g @plugin 'WillyV3/sessui'
TPM fetches the release binary for your machine (Linux or macOS, amd64 or arm64) and checks it against the release's checksums. No Go needed.
Go:
go install github.com/WillyV3/sessui@latest
Neither — grab a binary from releases, put it on your PATH, and bind it yourself:
bind-key s display-popup -E -w 112 -h 26 sessui
A popup larger than the terminal is an error in tmux. The TPM install shrinks
it to fit; with your own binding, use sizes like -w 90% -h 80% if you work
in small windows.
Needs tmux 3.7+. Earlier versions open the popup but never redraw it.
Before 3.3, transparent and borderless have no effect (see
Settings).
Keys
| Key | Does |
|---|---|
↑ ↓ |
move |
| any letter | filter — no / |
enter |
switch, or create a session named by the filter |
← → |
while creating: pick which machine |
ctrl+r |
rename |
ctrl+x |
kill |
ctrl+e |
settings — columns, width, theme, icons, hosts |
esc |
close |
Letters filter, so there are no j/k keys. Arrows are the nav.
Other machines
ctrl+e, arrow down to hosts. Your ~/.ssh/config is already the list —
space watches one and its sessions join the table.
hosts ● build-box ● laptop 1 ○ desk-pi ○ old-mac ›
● up · ○ down · ◌ still asking. Reachable machines sort first. Nothing is
polled until you pick something. Put the cursor on a ○ and the row says what
ssh said — a mistyped name, a sleeping laptop and a captive portal are
different problems.
Outside tmux, sessui -hosts prints the same thing as text: every host, its
sessions, or why it did not answer.
enter on a remote session attaches over ssh. Going back to it later is
instant: the connection stays open in the background. The session is one row
before and after, under its own name on its own machine. Kill and rename act
on the session itself, on its machine, and the kill prompt says which.
Inside a remote session there is one tmux, the far one. Your local tmux steps aside for that session: its prefix, its shortcuts and its status line are off, so every key and click goes to the machine you are looking at. Your other sessions are untouched.
One key stays yours: prefix s opens this machine's sessui, also from inside
a remote session. Every other prefix key (prefix c, prefix d, ...) goes to
the far tmux as you typed it. This comes with the TPM popup; a binding of your
own gets the bare view, where the far machine's keys are all there is.
- Back:
prefix sand pick where to go, or detach (prefix d): the view closes and you are in the local session you came from. The remote session keeps running either way. - Copying: selection and copy mode are the far tmux's. What you copy
reaches this machine's clipboard only with
set -g set-clipboard onin your local tmux.conf; tmux's default keeps it on the far machine. - Stuck connection:
enter~.makes ssh hang up, which does the same. A dead connection also closes by itself after about 45 seconds. - After a tmux restart: tmux-resurrect brings an open remote session back
as a plain local shell named
host/name. It is listed as the local session it now is, and the real one opens beside it. Kill the leftover when you like (^x). - Upgrading from v0.4.17 or older: a remote session that was open across
the upgrade shows twice until it is closed (
prefix dinside it). - sessui on the far machine too: you only reach its list from inside a view when the two machines have different prefixes, or with a binding of your own. Its own sessions switch as usual. It will not open a session on a third machine, or lead you back to the one you are sitting at: it names the keys that detach and tells you to open it from your own machine.
Creating: type a name, ←→ to pick a machine, enter. Plain enter still
creates locally.
Needs: ssh -o BatchMode=yes <host> true works (key auth, no prompt), and
tmux on the far end. Nothing gets installed there. Since it shells out to ssh,
your ~/.ssh/config does the work — ProxyJump, certs, agent forwarding,
Tailscale names.
Settings
ctrl+e edits the real table, live. esc applies, ctrl+z throws it away,
ctrl+r resets.
Popup size lives in tmux, because tmux needs it before sessui starts:
| Option | Default | |
|---|---|---|
@sessui-key |
s |
prefix + <key> |
@sessui-width |
112 |
the table wants ~112 columns |
@sessui-height |
26 |
Everything else is ~/.config/sessui/config.json, written for you by ctrl+e:
| Key | Values | |
|---|---|---|
icons |
nerd | ascii |
ascii for terminals without a Nerd Font |
theme.palette |
auto | terminal | dark | light |
auto follows the Omarchy theme where there is one, and is terminal everywhere else: your terminal's own sixteen colours, so it matches any terminal theme |
transparent |
false | true |
the popup takes the terminal's background (wallpaper, blur) instead of the palette's; next open (TPM popup, see below) |
borderless |
false | true |
a flush edge instead of tmux's popup border; next open (TPM popup, see below) |
columns |
[{"id","width"}] |
which columns, in what order |
hosts |
["alias"] |
machines to watch |
The TPM popup is filled with the palette's background, inside your own tmux
popup border (popup-border-lines, popup-border-style). Two rows in ctrl+e
change that, and both show the next time you open sessui:
- fill
solidis the palette's background, so alightpalette is readable on a dark terminal.transparentis the terminal's background instead. Theterminalpalette has no background of its own, so there the fill is tmux'spopup-style. - border
offreplaces the border with a row of blank cells in the fill's style, so the popup is one flush block. A drawn line sits in the middle of its cell, so a fill could only stop short of it or run past it.
sessui paints its own background on every frame, so a change of palette or of
Omarchy theme shows at once, and fill works with a binding of your own too.
The border is tmux's to draw: it follows at the next open, border off needs
the TPM popup, and both need tmux 3.3+ (display-popup -b, -s, -S).
config.json is read each time the popup opens, so a change made by hand (or
by a dotfiles sync) shows at the next open too.
Log
sessui keeps a local log of what it did: each start (version, tmux, whether it
is a view from another tmux, whether the terminal is UTF-8), each switch,
attach, kill and rename with its outcome and tmux's own error text, and each
time a watched host goes up or down. One JSON object a line in
~/.local/state/sessui/sessui.log ($XDG_STATE_HOME), readable only by you,
moved aside to sessui.log.1 past 1 MB. It never leaves the machine.
sessui -log prints the path.
When an agent needs you
A session stopped on a question or a permission prompt moves to the top of the list, blinks, and says what it is waiting for:
needs you · approve Bash: make install
sessui does not read the agent's screen to learn this. The agent says so itself, with the program status protocol (OSC 7501), and tmux passes it on. Nothing here is specific to one agent: whatever speaks the protocol is heard, in any pane, on this machine or another. Tested with Claude Code and pi, neither of which needed any setup.
tmux carries the protocol from the version after 3.8 (its main branch since
November 2026), and an agent only starts reporting once it is restarted inside
one. On an older tmux the terminal bell is all there is: a session that rings
shows needs you until you visit it. A bell cannot say what for, and an agent
set to ring when it finishes a turn will read the same as one asking.
With cp3
Running cp3? sessui matches
each session to its peer by directory and adds a peer column — up or down,
what it's working on, ✉ when it owes you a reply. No config; it reads
cp3 peers if cp3 is there. Without it the column disappears.
Docs
Architecture · Security · Gotchas
License
MIT
Directories
¶
| Path | Synopsis |
|---|---|
|
internal
|
|
|
session
Package session is the data layer: it shells out to tmux and cp3, parses their output, and exposes a plain Session struct.
|
Package session is the data layer: it shells out to tmux and cp3, parses their output, and exposes a plain Session struct. |
|
ui
Package ui is the bubbletea layer.
|
Package ui is the bubbletea layer. |