-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
97 lines (80 loc) · 3.21 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
#Prefix is Ctrl-a
set -g prefix C-a
bind C-a send-prefix
unbind C-b
set -sg escape-time 1
set -g base-index 1
setw -g pane-base-index 1
#Mouse works as expected
set -g mouse on
setw -g monitor-activity on
set -g visual-activity on
set -g mode-keys vi
set -g history-limit 50000
# y and p as in vim
bind Escape copy-mode
unbind p
bind p paste-buffer
#bind -t vi-copy 'v' begin-selection
#bind -t vi-copy 'y' copy-selection
# set main vertical window width
set-option -g main-pane-height 95
set-option -g main-pane-width 140
# extra commands for interacting with the ICCCM clipboard
bind C-c run "tmux save-buffer - | xclip -i -sel clipboard"
bind C-v run "tmux set-buffer \"$(xclip -o -sel clipboard)\"; tmux paste-buffer"
# easy-to-remember split pane commands
bind | split-window -h
bind - split-window -v
unbind '"'
unbind %
set -g default-terminal "screen-256color"
set-option -g pane-active-border-fg blue
source-file "${HOME}/.tmux.colors"
# Smart pane switching with awareness of vim splits
is_vim='echo "#{pane_current_command}" | grep -iqE "(^|\/)g?(view|n?vim?)(diff)?$"'
bind -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
bind -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
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"
bind C-l send-keys 'C-l'
bind -n C-Right next-window
bind -n C-Left next-window
# reload config
bind R source-file ~/.tmux.conf \; display-message "Config reloaded..."
#tmux plugin manager
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-yank'
# my plugins
set -g @plugin 'tmux-plugins/tmux-online-status'
## Colors
# This tmux statusbar config was created by tmuxline.vim
# on Thu, 30 Apr 2015
set -g status-bg "colour234"
set -g message-command-fg "colour255"
set -g status-justify "left"
set -g status-left-length "100"
set -g status "on"
set -g pane-active-border-fg "colour190"
set -g message-bg "colour238"
set -g status-right-length "100"
set -g status-right-attr "none"
set -g message-fg "colour255"
set -g message-command-bg "colour238"
set -g status-attr "none"
set -g status-utf8 "on"
set -g pane-border-fg "colour238"
set -g status-left-attr "none"
setw -g window-status-fg "colour85"
setw -g window-status-attr "none"
setw -g window-status-activity-bg "colour234"
setw -g window-status-activity-attr "none"
setw -g window-status-activity-fg "colour190"
setw -g window-status-separator ""
setw -g window-status-bg "colour234"
set -g status-left "#[fg=colour17,bg=colour190] #S #[fg=colour190,bg=colour234,nobold,nounderscore,noitalics]"
set -g status-right "#[fg=colour238,bg=colour234,nobold,nounderscore,noitalics]#[fg=colour255,bg=colour238] %Y-%m-%d %H:%M #[fg=colour190,bg=colour238,nobold,nounderscore,noitalics]#[fg=colour17,bg=colour190] #h "
setw -g window-status-format "#[fg=colour85,bg=colour234] #I #[fg=colour85,bg=colour234] #W "
setw -g window-status-current-format "#[fg=colour234,bg=colour238,nobold,nounderscore,noitalics]#[fg=colour255,bg=colour238] #I #[fg=colour255,bg=colour238] #W #[fg=colour238,bg=colour234,nobold,nounderscore,noitalics]"