diff --git a/tmux/.config/tmux/tmux.conf b/tmux/.config/tmux/tmux.conf index fcd03d7..5e477b4 100644 --- a/tmux/.config/tmux/tmux.conf +++ b/tmux/.config/tmux/tmux.conf @@ -1,6 +1,6 @@ # Layout of this conf file: # 1. Global Settings -# 2. Keybinds +# 2. Plugins # 3. Keybinds # 4. Theme @@ -27,11 +27,8 @@ set -g mouse on # allow truecolor support set -g default-terminal 'xterm-256color' set -ga terminal-overrides ',xterm-256color:Tc' -# Set Cursor terminal override, so nvim can change cursor style when changing modes -# more info see nvim, :help tui-cursor-shape -# LEGACY: this should not be necessary anymore -# set -ga terminal-overrides '*:Ss=\E[%p1%d q:Se=\E[ q' set -g status-keys vi +set-window-option -g mode-keys vi set -g history-limit 10000 # Screen size is based on the smallest client looking at the current windows, not the smallest @@ -111,6 +108,12 @@ bind-key '-' split-window -v -c '#{pane_current_path}' # Open a sessions chooser bind C-s split-window -v "tmux list-sessions | sed -E 's/:.*$//' | grep -v \"^$(tmux display-message -p '#S')\$\" | fzf --reverse | xargs tmux switch-client -t" +# Make visual selections act a little more like vim +bind-key -T copy-mode-vi v send -X begin-selection +bind-key -T copy-mode-vi V send -X select-line +bind-key -T copy-mode-vi y send -X copy-pipe-and-cancel 'wl-copy' \; send -X rectangle-off +bind-key -T copy-mode-vi 'C-v' send -X begin-selection \; send -X rectangle-on + ##################### ## 4. THEME ## #####################