tmux new -s session_name
creates a new tmux session named session_name
tmux attach -t session_name
attaches to an existing tmux session named session_name
tmux switch -t session_name
switches to an existing session named session_name
tmux list-sessions
lists existing tmux sessions
tmux detach (prefix + d)
detach the currently attached session
tmux rename-session [-t current-name] [new-name] | prefix + $
rename session
tmux new-window (prefix + c)
create a new window
tmux select-window -t :0-9 (prefix + 0-9)
move to the window based on index
tmux rename-window (prefix + ,)
rename the current window
tmux list-windows
Lists all windows
tmux kill-window (prefix + &)
Kill current window
tmux split-window (prefix + ")
splits the window into two vertical panes
tmux split-window -h (prefix + %)
splits the window into two horizontal panes
tmux swap-pane -[UDLR] (prefix + { or })
swaps pane with another in the specified direction
tmux kill-pane (prefix + x)
Kills the active pane
tmux select-pane -[UDLR]
selects the next pane in the specified direction
tmux select-pane -t :.+
selects the next pane in numerical order
Resize pane down
prefix + :resize-pane -D <new_size>
Resize pane up
prefix + :resize-pane -U <new_size>
Resize pane left
prefix + :resize-pane -L <new_size>
Resize pane right
prefix + :resize-pane -R <new_size>
To turn on scroll mode in a pane
prefix + [
then you can use standard navigation keys
To turn off scroll mode in a pane press q
set -g @plugin 'tmux-plugins/tmux-resurrect'
prefix C + s
Save session
prefix C+r
Restore session