feat(tmux): rebind prefix r to rename window, prefix R to reload

frees the more frequent rename action to the lowercase key.
This commit is contained in:
publicmatt
2026-05-11 13:50:43 -07:00
parent 7f859e74aa
commit a619e6589e

View File

@@ -427,6 +427,12 @@ set -g mode-keys vi
# display a message after toggling mouse support # display a message after toggling mouse support
bind m run "cut -c3- '#{TMUX_CONF}' | sh -s _toggle_mouse" \; display 'mouse #{?#{mouse},on,off}' bind m run "cut -c3- '#{TMUX_CONF}' | sh -s _toggle_mouse" \; display 'mouse #{?#{mouse},on,off}'
# rename current window (override Oh my tmux! reload-on-r)
bind r command-prompt -I "#W" "rename-window '%%'" #!important
# reload configuration on R instead of r
bind R run "sh -c '\"\$TMUX_PROGRAM\" \${TMUX_SOCKET:+-S \"\$TMUX_SOCKET\"} source \"\$TMUX_CONF\"'" \; display "#{TMUX_CONF} sourced"
# copy to clipboard on mouse drag release # copy to clipboard on mouse drag release
bind -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "pbcopy" bind -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel "pbcopy"