Embers is a Rust terminal multiplexer built around a headless server, a terminal UI client, and an automation-friendly command line interface. It manages sessions, windows, panes, floating popups, detachable terminal buffers, scrollback/history, and configurable key bindings through a Rhai-based config API.
The project is still early, but the shape is already close to a tmux-like workflow with a programmable client layer and durable PTY-backed buffers.
- Headless Unix-socket server with interactive terminal clients
- Sessions, windows, panes, tab trees, splits, and floating popups
- Durable terminal buffers that can be detached, reattached, moved, and captured
- Scrollback, visible snapshots, search, selection, and yank-oriented client behavior
- Scriptable Rhai config for key bindings, modes, actions, themes, tab bars, and hooks
- CLI commands for scripting and automation
- FlatBuffers protocol shared by the client and server crates
- Rust
1.92or newer flatcfrom FlatBuffers25.12.19mdbookwhen regenerating the config API docs
If you use Nix, the included flake provides the pinned development tools:
nix developWithout Nix, make sure flatc is available on PATH before building.
Build the workspace:
cargo build --workspaceRun the interactive client:
cargo run -p embers-cli --bin embersRunning embers without a subcommand starts the background server if needed, creates or selects the default session, and attaches the terminal UI. Press Ctrl-q to leave the interactive client.
You can also install and run the binary directly:
cargo install --path crates/embers-cli
embersEmbers exposes both an interactive client and command-oriented operations through the embers binary.
embers --help
embers list-sessions
embers new-session work
embers new-window --title logs -- tail -f app.log
embers split-window --horizontal -- cargo test
embers list-panes
embers capture-paneBy default, Embers uses a runtime socket at:
$XDG_RUNTIME_DIR/embers/embers.sock, whenXDG_RUNTIME_DIRis set/run/user/<uid>/embers/embers.sock, when available/tmp/embers-<uid>/embers.sock, as a fallback
Override the socket with either --socket or EMBERS_SOCKET:
embers --socket /tmp/my-embers.sock list-sessions
EMBERS_SOCKET=/tmp/my-embers.sock embers attachUseful subcommand groups include:
session:new-session,list-sessions,rename-session,kill-sessionwindow:new-window,list-windows,select-window,rename-window,kill-windowpane:split-window,list-panes,select-pane,resize-pane,send-keys,capture-pane,kill-panebuffer:buffer show,buffer history,buffer reveal,buffer pipenode:node zoom,node swap,node break,node join-buffer,node move-before,node move-afterpopup:display-popup,kill-popup
Embers loads configuration in this order:
--config <path>EMBERS_CONFIG- The platform config directory for the
embersapplication, typically~/.config/embers/config.rhaion Linux - Built-in defaults
User config is loaded as an overlay on top of the built-in defaults. The built-in config enables mouse behavior, scroll/search/select modes, and basic selection bindings.
This repository includes a fuller example at config.rhai. It defines a tmux-inspired leader, smart navigation for Vim/Neovim panes, split/tab helpers, popup helpers, history views, and a custom tab bar/theme.
Run with an explicit config while developing:
embers --config ./config.rhaiThe generated config API reference lives in docs/config-api, with a rendered mdBook copy in docs/config-api-book.
Run the test suite:
cargo test --workspaceRun formatting and lint checks:
cargo fmt --all -- --check
cargo clippy --workspace --all-targets -- -D warningsRegenerate the config API docs:
cargo gen-docsThe CI workflow also runs an ignored PTY smoke test:
cargo test -p embers-test-support pty_round_trips_input -- --ignoredcrates/embers-core: shared IDs, geometry, snapshots, diagnostics, and error typescrates/embers-protocol: FlatBuffers schema, codec, framing, and protocol clientcrates/embers-server: server state, persistence, terminal backend, and PTY runtime managementcrates/embers-client: client state, rendering, input handling, configuration, scripting, and docs generationcrates/embers-cli:embersbinary, interactive terminal UI, and CLI command implementationscrates/embers-test-support: shared test harnesses for server, protocol, PTY, and CLI tests
The docs directory contains design notes that are useful when changing behavior:
docs/terminal-runtime.md: PTY-backed buffer ownership and lifecycledocs/terminal-backend-boundary.md: server/backend responsibility boundarydocs/terminal-capture-model.md: terminal capture and snapshot modeldocs/input-routing.md: input routing modeldocs/activity-bell-policy.md: activity and bell state policydocs/render-source-contract.md: rendering source-of-truth contract
This workspace is licensed under GPL-3.0-only.