JoJo
JoJo

Reputation: 1447

how to do quick pane cycling in Tmux

there, recently I decide to hug with Tmux and to configure the .tmux.conf by myself. I am trying to get the command of quick pane cycling now. Here I have a short configure lines referenced from others:

# quick pane cycling
unbind ^A
bind ^A select-pane -t :.+

Does anyone know what's the meaning of these three lines? I tried several times with my Tmux, but still cannot find the shortcut command related to these three lines.

Upvotes: 0

Views: 1810

Answers (2)

ArulPrasad
ArulPrasad

Reputation: 33

^A means Control+A.

If you add this to your config file, and then tmux source-file .tmux.conf, you can cycle between your panes by hitting Control+A.

Upvotes: 2

Madhav Prabhoo
Madhav Prabhoo

Reputation: 326

As pointed out in the comments, I'll explain and post the relevant sections of man page

unbind ^A

Disassociates any command previously bound to C-b C-a, freeing ^A for the following

bind ^A select-pane -t :.+

Cycles to the next pane in the current window. From man page

select-pane [-lDLRU] [-t target-pane]
(alias: selectp)
Make pane target-pane the active pane in window target-window.

For specification of 'target-pane'

target-pane takes a similar form to target-window but with the optional addition of a period followed by a pane index, for example: mysession:mywindow.1. If the pane index is omitted, the currently active pane in the specified window is used. If neither a colon nor period appears, tmux first attempts to use the argument as a pane index; if that fails, it is looked up as for target-window. A ‘+’ or ‘-’ indicate the next or previous pane index, respectively.

Upvotes: 2

Related Questions