-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
28 lines (22 loc) · 1.32 KB
/
.tmux.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
set -g default-terminal "screen-256color"
set -ga terminal-overrides ",xterm-256color*:Tc"
set-option -g -q mouse on
# Use vim keybindings in copy mode
setw -g mode-keys vi
set-window-option -g xterm-keys on
set-option -g set-clipboard on
# Fix scrolling
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'copy-mode -e'"
bind P paste-buffer
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi y send-keys -X copy-selection
# bind-key -T copy-mode-vi y send-keys -X copy-pipe "xclip -sel clip -i"
bind-key -T copy-mode-vi y send-keys -X copy-pipe "pbcopy"
bind-key -T copy-mode-vi r send-keys -X rectangle-toggle
bind-key -T edit-mode-vi Up send-keys -X history-up
bind-key -T edit-mode-vi Down send-keys -X history-down
# unbind-key -T copy-mode-vi Space ; bind-key -T copy-mode-vi v send-keys -X begin-selection
# unbind-key -T copy-mode-vi Enter ; bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy"
# unbind-key -T copy-mode-vi C-v ; bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
unbind-key -T copy-mode-vi [ ; bind-key -T copy-mode-vi [ send-keys -X begin-selection
unbind-key -T copy-mode-vi ] ; bind-key -T copy-mode-vi ] send-keys -X copy-selection