# These are the default commands executed for the keybindings in tmux-modal. # This file will be used (sourced) by the main script `tmux-modal.tmux` when # tmux loads. Users can however load their own custom commands file by copying # this file, make any changes and then tell tmux-modal to load the custom file # instead with tmux option `modal-commands-conf`. For example, put this is in # your `.tmux.conf`: # # set -g @modal-commands-conf /path/to/my-tmux-modal-commands.conf # # The syntax is the same as for any other Bash file: # # CMD_COPY_MODE='copy-mode' # CMD_WIN_RENAME='command-prompt -I "#W" "rename-window -- \"%%\""' # CMD_GOTO_WIN_NEXT='select-window -t :+' # CMD_GOTO_SESS_PREV='switch-client -p' # # This redefines the variables for the commands for the keybindings # `KBD_COPY_MODE`, `KBD_WIN_RENAME`, `KBD_GOTO_WIN_NEXT` and # `KBD_GOTO_SESS_PREV`, respectively. The variable value is thus the command as # a Bash string (make sure to escape necessary characters). # # Note that the variable names follow the same pattern as the keybindings in # `keybindings.conf`. See the file `keybindings.conf` for more information. # Enter copy mode. CMD_COPY_MODE='copy-mode' # Paste buffer (e.g. from copy mode). CMD_PASTE='paste-buffer' # Open the tmux command prompt. CMD_CMD_PROMPT='command-prompt' # Window command prefix. ## Select window 0 (window command alias for CMD_GOTO_WIN_0). CMD_WIN_GOTO_0='select-window -t :0' ## Select window 1 (window command alias for CMD_GOTO_WIN_1). CMD_WIN_GOTO_1='select-window -t :1' ## Select window 2 (window command alias for CMD_GOTO_WIN_2). CMD_WIN_GOTO_2='select-window -t :2' ## Select window 3 (window command alias for CMD_GOTO_WIN_3). CMD_WIN_GOTO_3='select-window -t :3' ## Select window 4 (window command alias for CMD_GOTO_WIN_4). CMD_WIN_GOTO_4='select-window -t :4' ## Select window 5 (window command alias for CMD_GOTO_WIN_5). CMD_WIN_GOTO_5='select-window -t :5' ## Select window 6 (window command alias for CMD_GOTO_WIN_6). CMD_WIN_GOTO_6='select-window -t :6' ## Select window 7 (window command alias for CMD_GOTO_WIN_7). CMD_WIN_GOTO_7='select-window -t :7' ## Select window 8 (window command alias for CMD_GOTO_WIN_8). CMD_WIN_GOTO_8='select-window -t :8' ## Select window 9 (window command alias for CMD_GOTO_WIN_9). CMD_WIN_GOTO_9='select-window -t :9' ## Select window with tree view (window command alias for CMD_GOTO_WIN_TREE). CMD_WIN_GOTO_TREE='choose-tree -Zw' ## Select window with index (window command alias for CMD_GOTO_WIN_INDEX). CMD_WIN_GOTO_INDEX='command-prompt -p index "select-window -t \":%%\""' ## Select left pane. CMD_WIN_PANE_LEFT='select-pane -L' ## Select right pane. CMD_WIN_PANE_RIGHT='select-pane -R' ## Select above pane. CMD_WIN_PANE_UP='select-pane -U' ## Select below pane. CMD_WIN_PANE_DOWN='select-pane -D' ## Delete window pane. CMD_WIN_PANE_DEL='kill-pane' ## Select previous window (window command alias for CMD_GOTO_WIN_PREV). CMD_WIN_PREV='select-window -t :-' ## Select next window (window command alias for CMD_GOTO_WIN_NEXT). CMD_WIN_NEXT='select-window -t :+' ## Delete window. CMD_WIN_DEL='kill-window' ## Create new window. CMD_WIN_CREATE='new-window' ## Select last window (window command alias for CMD_GOTO_WIN_LAST). CMD_WIN_LAST='last-window' ## Zoom pane. CMD_WIN_ZOOM='resize-pane -Z' ## Break pane. CMD_WIN_BREAK='break-pane' ## Display pane numbers. CMD_WIN_NR='display-panes' ## Rename window. CMD_WIN_RENAME='command-prompt -I "#W" "rename-window -- \"%%\""' ## Split command prefix. ### Split window pane right. CMD_WIN_SPLIT_RIGHT='split-window -h' ### Split window pane down. CMD_WIN_SPLIT_DOWN='split-window' ## Move command prefix. ### Move window pane up. CMD_WIN_MOVE_UP='swap-pane -U' ### Move window pane down. CMD_WIN_MOVE_DOWN='swap-pane -D' ## Arrange command prefix. ### Arrange window layout 1 ("even-horizontal"). CMD_WIN_ARRANGE_1='select-layout even-horizontal' ### Arrange window layout 2 ("even-vertical"). CMD_WIN_ARRANGE_2='select-layout even-vertical' ### Arrange window layout 3 ("main-horizontal"). CMD_WIN_ARRANGE_3='select-layout main-horizontal' ### Arrange window layout 4 ("main-vertical"). CMD_WIN_ARRANGE_4='select-layout main-vertical' ##q Resize command prefix. ### Resize pane left one step. CMD_WIN_RESIZE_LEFT='resize-pane -L' ### Resize pane right one step. CMD_WIN_RESIZE_RIGHT='resize-pane -R' ### Resize pane down one step. CMD_WIN_RESIZE_DOWN='resize-pane -D' ### Resize pane up one step. CMD_WIN_RESIZE_UP='resize-pane -U' ### Resize pane left multiple steps. CMD_WIN_RESIZE_MULTI_LEFT='resize-pane -L 5' ### Resize pane right multiple steps. CMD_WIN_RESIZE_MULTI_RIGHT='resize-pane -R 5' ### Resize pane down multiple steps. CMD_WIN_RESIZE_MULTI_DOWN='resize-pane -D 5' ### Resize pane up multiple steps. CMD_WIN_RESIZE_MULTI_UP='resize-pane -U 5' # Session command prefix. ## Detach session. CMD_SESS_DETACH='detach-client' ## Select previous session (session command alias for CMD_GOTO_SESS_PREV). CMD_SESS_PREV='switch-client -p' ## Select next session (session command alias for CMD_GOTO_SESS_NEXT). CMD_SESS_NEXT='switch-client -n' ## Select session with a tree view (session command alias for ## CMD_GOTO_SESS_TREE). CMD_SESS_TREE='choose-tree -Zs' ## Delete session. CMD_SESS_DEL='kill-session' ## Rename session. CMD_SESS_RENAME='command-prompt -I "#S" "rename-session \"%%\""' # "Go to" command prefix. ## Go to window command prefix. CMD_GOTO_WIN= ### Go to window 0. CMD_GOTO_WIN_0='select-window -t :0' ### Go to window 1. CMD_GOTO_WIN_1='select-window -t :1' ### Go to window 2. CMD_GOTO_WIN_2='select-window -t :2' ### Go to window 3. CMD_GOTO_WIN_3='select-window -t :3' ### Go to window 4. CMD_GOTO_WIN_4='select-window -t :4' ### Go to window 5. CMD_GOTO_WIN_5='select-window -t :5' ### Go to window 6. CMD_GOTO_WIN_6='select-window -t :6' ### Go to window 7. CMD_GOTO_WIN_7='select-window -t :7' ### Go to window 8. CMD_GOTO_WIN_8='select-window -t :8' ### Go to window 9. CMD_GOTO_WIN_9='select-window -t :9' ### Go to window with tree view. CMD_GOTO_WIN_TREE='choose-tree -Zw' ### Go to window with index. CMD_GOTO_WIN_INDEX='command-prompt -p index "select-window -t \":%%\""' ### Go to previous window. CMD_GOTO_WIN_PREV='select-window -t :-' ### Go to next window. CMD_GOTO_WIN_NEXT='select-window -t :+' ### Go to last window. CMD_GOTO_WIN_LAST='last-window' ## Go to session command prefix. ### Go to previous session. CMD_GOTO_SESS_PREV='switch-client -p' ### Go to next session. CMD_GOTO_SESS_NEXT='switch-client -n' ### Go to session with tree view. CMD_GOTO_SESS_TREE='choose-tree -Zs'