Skip to content

Instantly share code, notes, and snippets.

@ktzar
Last active August 19, 2022 14:22
Show Gist options
  • Save ktzar/9c733cf6f40cd3ac3b761d9898bc5d86 to your computer and use it in GitHub Desktop.
Save ktzar/9c733cf6f40cd3ac3b761d9898bc5d86 to your computer and use it in GitHub Desktop.
TMUX cheatsheet

Commands to open Tmux

# Start new session
tmux
# List sessions
tmux ls
# Attach to a session
tmux a -t sess_num
# Rename a session
tmux rename-session -t 0 database
# Kill all sessions
tmux kill-server

Commands inside Tmux

Command Effect
c create
% Split horizontally
" Split vertically
p previous
n next
; toggle between previous
d detach from tmux
z zoom → make current panel fullscreen
Arrow Move to a panel
C-Arrow Resize
Esc Arrow Resize 5 units
, Rename current session
x Close the current pane
s Show sessions
w show window+pane list
q show pane numbers
( & ) previous and next session
{ & } swap pane with the previous (in order, top bottom, left right)
Space Toggle layout
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment