Skip to content

Instantly share code, notes, and snippets.

@ph4ge
Created December 6, 2020 22:51
Show Gist options
  • Save ph4ge/4ba7d62cfa1647bbe633e064cb2c1705 to your computer and use it in GitHub Desktop.
Save ph4ge/4ba7d62cfa1647bbe633e064cb2c1705 to your computer and use it in GitHub Desktop.
A few tmux shortcuts
# create new session
$ tmux new -s session1
# detach a session
$ Prefix d
# attach to session
$ tmux attach
$ tmux attach -t a_session
# kill session
$ tmux kill-session -t a_session
# list all sessions
$ tmux ls
# create a new window
$ Prefix c
# rename a session
$ Prefix ,
# navigate between windows
$ Prefix n
$ Prefix p
$ Prefix w
# close a window
$ Prefix &
# split vertically
$ Prefix %
# split horizontally
$ Prefix "
# cycle through panes
$ Prefix o
$ Prefix Up, Down, Left, Right
# change pane layouts
$ Prefix Spacebar
# kill a pane
$ Prefix x
# list buffers
$ Prefix #
# list all windows
$ Prefix w
# list all sessions
$ Prefix s
# copy text
# first enter copy mode
$ Prefix [
# move cursor and select text
$ ctrl + space
# save selected text
$ alt + w
# paste content
$ Prefix ]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment