-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
128 lines (99 loc) · 3.53 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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
# Change prefix key to Ctrl+a
unbind C-b
set -g prefix C-a
# Screen-like behavior for nexted tmux sessions
bind C-a send-prefix
bind a send-prefix
# Default terminal
set -g default-command "exec zsh"
set -g default-terminal "screen-256color"
# Refresh some key environment variables, and bind a key so we can
# do the same manually if necessary
set -g update-environment "PATH DISPLAY SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY"
bind E set -g update-environment "PATH DISPLAY SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY"
# Fix scrolling issues with Shift-{PgUp,PgDown}
#set -g terminal-overrides 'xterm*:smcup@:rmcup@'
setw -g alternate-screen off
# Change window number to start at 1 so as to match
# the leftmost number on the keyboard
set-option -g base-index 0
# Last active window
bind C-c new-window -c '#{pane_current_path}'
bind c new-window -c '#{pane_current_path}'
unbind l
bind C-\\ last-window
bind C-n next-window
bind C-p previous-window
# Copy mode
#unbind [
bind Escape copy-mode
# Use Vi mode
setw -g mode-keys vi
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'C-v' send -X rectangle-toggle
bind-key -T copy-mode-vi 'y' send -X copy-selection
bind ] paste-buffer
# Make mouse useful in copy mode
#setw -g mode-mouse on
# More straight forward key bindings for splitting
unbind %
bind | split-window -v -c '#{pane_current_path}'
bind h split-window -v -c '#{pane_current_path}'
unbind '"'
bind - split-window -h -c '#{pane_current_path}'
bind v split-window -h -c '#{pane_current_path}'
# History
set -g history-limit 50000
# Pane
unbind o
# bind C-s down-pane
# Terminal emulator window title
set -g set-titles on
set -g set-titles-string "#H: '#W'"
#setw -g automatic-rename on
#set -g allow-rename off
# Status Bar
#set -g status-keys emacs
#set -g status-bg black
#set -g status-fg white
#set -g status-interval 1
#set -g status-justify left
##set -g status-left '#[fg=green,bold]#H#[default]'
##set -g status-right '#[fg=yellow]#(cut -d " " -f 1-4 /proc/loadavg) #[fg=green]%Y-%m-%d %H:%M:%S#[default]'
##set -g status-right "#{sysstat_cpu} | #{sysstat_mem} | #{sysstat_swap} | #{sysstat_loadavg} | #[default]#H | #[fg=green]%Y-%m-%d %H:%M:%S"
#set -g status-right "#{sysstat_cpu} | #{sysstat_mem} | #{sysstat_swap} | #[default]#H | #[fg=green]%Y-%m-%d %H:%M:%S"
#set -g status-right-length 100
set -g status-right ''
# Notifying if other windows has activities
setw -g monitor-activity on
set -g visual-activity on
# Highlighting the active window in status bar
setw -g window-status-current-style "bg=red"
# Clock
setw -g clock-mode-colour green
setw -g clock-mode-style 24
# vim - make escape have an instantaneous effect
set -sg escape-time 0
# Reload config file
bind L source-file ~/.tmux.conf
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'samoshkin/tmux-plugin-sysstat'
#set -g @plugin 'seebi/tmux-colors-solarized'
set -g @plugin 'arcticicestudio/nord-tmux'
# Plugin Configuration
set -g @resurrect-strategy-vim 'session'
set -g @resurrect-capture-pane-contents 'on'
set -g @resurrect-save-shell-history 'off'
set -g @continuum-save-interval '15'
set -g @continuum-restor 'on'
set -g @colors-solarized 'dark'
set -g @nord_tmux_show_status_content "0"
bind C-l send-keys 'C-l' # Restoring clear screen
# vim-tmux-focus-events
set -g focus-events on
# Initialize TPM
run '~/.tmux/plugins/tpm/tpm'