Skip to content

Instantly share code, notes, and snippets.

@datousir
Forked from elyezer/tmux_cheat_sheet.md
Created June 5, 2017 10:37
Show Gist options
  • Save datousir/92aa97c4870a2154e97521aabd7a6d27 to your computer and use it in GitHub Desktop.
Save datousir/92aa97c4870a2154e97521aabd7a6d27 to your computer and use it in GitHub Desktop.

Revisions

  1. @elyezer elyezer created this gist Jan 7, 2015.
    51 changes: 51 additions & 0 deletions tmux_cheat_sheet.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,51 @@
    tmux cheat sheet
    ==============

    Session Control (from the command line)
    ---------------------------------------
    tmux Start a new session
    tmux attach Re-attach a detached session
    tmux attach -d Re-attach a detached session (and detach it from elsewhere)

    Pane Control
    ------------
    Ctrl-B " Split pane horizontally
    Ctrl-B % Split pane vertically
    Ctrl-B o Next pane
    Ctrl-B ; Previous pane
    Ctrl-B x Kill current pane
    Ctrl-B ! Kill all panes but the current one
    Ctrl-B Ctrl-O Swap panes
    Ctrl-B t Display clock
    Ctrl-B q Transpose two letters (delete and paste)

    Window Control
    --------------
    Ctrl-B c Create new window
    Ctrl-B d Detach from session
    Ctrl-B , Rename a window
    Ctrl-B w List windows

    Copy-Mode (vi)
    --------------
    Ctrl-B [ Enter copy mode
    Ctrl-B G Bottom of history
    Ctrl-B g Top of histroy
    Ctrl-B Enter Copy selection
    Ctrl-B p Paste selection
    Ctrl-B k Cursor Up
    Ctrl-B j Cursor Down
    Ctrl-B h Cursor Left
    Ctrl-B l Cursor Right

    Copy-Mode (Emacs)
    -----------------
    Ctrl-B [ Enter copy mode
    Ctrl-B M-< Bottom of history
    Ctrl-B M-> Top of histroy
    Ctrl-B M-w Copy selection
    Ctrl-B M-y Paste selection
    Ctrl-B Up Cursor Up
    Ctrl-B Down Cursor Down
    Ctrl-B Left Cursor Left
    Ctrl-B Right Cursor Right