-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
45 lines (31 loc) · 1.38 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
set -g default-terminal "screen-256color"
set-option -g default-command "reattach-to-user-namespace -l zsh"
#new mouse
set -g mouse on
# mouse
#set -g mode-mouse on
#set -g mouse-resize-pane on
#set -g mouse-select-pane on
#set -g mouse-select-window on
bind | split-window -h
bind - split-window -v
# http://robots.thoughtbot.com/tmux-copy-paste-on-os-x-a-better-future
# Use vim keybindings in copy mode
setw -g mode-keys vi
# Setup 'v' to begin selection as in Vim
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi y send-keys -X copy-pipe "reattach-to-user-namespace pbcopy"
# Update default binding of `Enter` to also use copy-pipe
unbind -T copy-mode-vi Enter
bind-key -T copy-mode-vi Enter send-keys -X copy-pipe "reattach-to-user-namespace pbcopy"
bind -T copy-mode-vi WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-vi WheelDownPane send-keys -X halfpage-down
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'"
bind -n WheelDownPane select-pane -t= \; send-keys -M
# http://zanshin.net/2013/09/05/my-tmux-configuration/
# set window and pane index to 0 (0 by default)
set-option -g base-index 0
setw -g pane-base-index 0
# reload ~/.tmux.conf using PREFIX r
bind r source-file ~/.tmux.conf \; display "Reloaded!"
set-option -g history-limit 20000