tmux
MX-01 // MULTIPLEXER
tmux lets you run multiple terminal sessions in a single window with split panes and session persistence.
Configuration
Section titled “Configuration”Config lives at ~/.config/tmux/tmux.conf.
Key Settings
Section titled “Key Settings”| Setting | Value |
|---|---|
| Prefix | Ctrl + Space (also Ctrl + B) |
| Base index | 1 (windows and panes) |
| Mouse | Enabled |
| Copy mode | Vi keybindings |
| Status bar | Top position, themed |
| Colors | 256 color with RGB overrides |
Key Bindings
Section titled “Key Bindings”All prefixed bindings require pressing Ctrl + Space first.
| Shortcut | Action |
|---|---|
| Prefix + h | Split horizontally |
| Prefix + v | Split vertically |
| Ctrl + Alt + Arrows | Navigate panes |
| Ctrl + Alt + Shift + Arrows | Resize panes |
| Prefix + x | Kill pane |
Windows
Section titled “Windows”| Shortcut | Action |
|---|---|
| Prefix + c | New window |
| Prefix + , | Rename window |
| Alt + 1-9 | Select window |
| Alt + Arrows | Navigate windows |
Sessions
Section titled “Sessions”| Shortcut | Action |
|---|---|
| Prefix + C | New session |
| Prefix + R | Rename session |
| Alt + Up/Down | Switch sessions |
Copy Mode
Section titled “Copy Mode”Enter copy mode with Prefix + [, then use Vi keys:
| Key | Action |
|---|---|
| v | Begin selection |
| y | Copy selection |
Dev Layouts
Section titled “Dev Layouts”Preconfigured tmux session layouts for development:
| Command | Layout | Description |
|---|---|---|
tdl [name] [dir] | Editor + terminal | nvim left (60%), terminal right |
tdlm [name] [dir] | Main dev | nvim top-left, terminal bottom-left, server right |
tsl [name] [dir] | Swarm | 4 equal panes |
tdl myproject ~/code/myproject # editor + terminaltdlm api ~/code/api # editor + terminal + servertsl workers ~/code/workers # 4 panes for parallel workIf a session with that name already exists, the command reattaches to it.
Customization
Section titled “Customization”Edit ~/.config/tmux/tmux.conf. The config uses Prefix + r to reload. Theme colors are managed by theme-set — switching themes updates tmux live.
The bash alias t attaches to an existing session or creates a new one:
t # attach or new session