From b2244fc7bafd907020eee92472cdbc47668950e5 Mon Sep 17 00:00:00 2001 From: bchanot Date: Tue, 6 Oct 2026 13:02:37 +0200 Subject: [PATCH] feat(tmux): option+arrow moves between panes without prefix --- tmux.conf | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tmux.conf b/tmux.conf index f65f79d..722b0f5 100644 --- a/tmux.conf +++ b/tmux.conf @@ -134,6 +134,13 @@ bind -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U" bind -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R" #bind -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l" +# Same moves on option+arrow (iTerm2 sends them as M-arrow; "Left Option key" +# must be Esc+ or the xterm preset). C-i/C-m were ruled out: they are Tab/Enter. +bind -n M-Left if-shell "$is_vim" "send-keys M-Left" "select-pane -L" +bind -n M-Down if-shell "$is_vim" "send-keys M-Down" "select-pane -D" +bind -n M-Up if-shell "$is_vim" "send-keys M-Up" "select-pane -U" +bind -n M-Right if-shell "$is_vim" "send-keys M-Right" "select-pane -R" + bind Escape copy-mode # bind vi-like 'normal' mode bind -Tcopy-mode-vi 'v' send -X begin-selection # bind vi-like visual mode bind -Tcopy-mode-vi 'y' send -X copy-pipe-and-cancel "pbcopy" # macOS copy