Skip to content

Instantly share code, notes, and snippets.

@rbento
Last active August 5, 2023 20:27
Show Gist options
  • Select an option

  • Save rbento/ed39742f1a8cdb18f813101730469cec to your computer and use it in GitHub Desktop.

Select an option

Save rbento/ed39742f1a8cdb18f813101730469cec to your computer and use it in GitHub Desktop.

Notes on tmux

tmux is a terminal multiplexer which enables easy switching between multiple programs running in one terminal, detach them (keep running in the background) and reattach them to a different terminal.

Screenshot 2023-08-05 at 3 05 41 PM

Create a session


Unnamed

tmux

Named

tmux new -s session-name

Rename

ctrl + b, $

List

tmux list-sessions
tmux ls

Attach

To most recent
tmux attach
tmux a
To target
tmux attach -t session-name
tmux a -t session-name

Switch

ctrl + b, s

Split Panes


Vertical

ctrl + b, %

Horizontal

ctrl + b, "

Zoom (toggle)

ctrl + z

Close

ctrl + d

Windows


Create

ctrl + c

Switch

Previous
ctrl + p
Next
ctrl + n
Close
ctrl + &

Resources


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment