-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtmux.conf
More file actions
120 lines (92 loc) · 3.05 KB
/
tmux.conf
File metadata and controls
120 lines (92 loc) · 3.05 KB
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
# +++++++++++++
# TMUX settings
# +++++++++++++
# Powerline
run-shell "powerline-daemon -q"
source "/home/cohesity/.local/lib/python3.4/site-packages/powerline/bindings/tmux/powerline.conf"
# Default terminal
set -g default-terminal "xterm-256color"
# Status bar
set -g status-bg colour234
set -g status-fg green
#Setting the prefix from `C-b` to `C-a`.
set-option -g prefix C-a
set-option -s escape-time 0
#Ensure that we can send `Ctrl-a` to other apps.
bind-key C-a send-prefix
#Splitting panes
bind-key h split-window -v -c "#{pane_current_path}"
bind-key v split-window -h -c "#{pane_current_path}"
#Reload the file with Prefix r.
bind-key r source-file ~/.tmux.conf \; display "Reloaded!"
#Moving between panes
bind-key -n S-Left select-pane -L
bind-key -n S-Down select-pane -D
bind-key -n S-Up select-pane -U
bind-key -n S-Right select-pane -R
#Moving between tabs
bind-key -n C-right next
bind-key -n C-left prev
#Pane switching using mouse
bind m \
set -g mode-mouse on \;\
set -g mouse-resize-pane on \;\
set -g mouse-select-pane on \;\
set -g mouse-select-window on \;\
display 'Mouse: ON'
bind M \
set -g mode-mouse off \;\
set -g mouse-resize-pane off \;\
set -g mouse-select-pane off \;\
set -g mouse-select-window off \;\
display 'Mouse: OFF'
#Start with window 1
set-option -g base-index 1
#make the key bindings work like emacs
set-option -g status-keys emacs
set-window-option -g mode-keys emacs
#Activity monitoring
set-option -g status on
set-window-option -g monitor-activity on
set-option -g visual-activity on
set-option -gw xterm-keys on
#Copy mode like screen
bind-key Escape copy-mode
#Set history limit
set-option -g history-limit 10000
#Bind key for synchronizing panes
bind-key y set-window-option synchronize-panes \; display "Synchronized!"
# Free original bindings
unbind-key C-b
unbind-key '"'
unbind-key %
#tmux plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-resurrect'
#tmux plugin manager
run '~/.tmux/plugins/tpm/tpm'
#Name window based on process
set-window-option -g automatic-rename on
# pane border
set-option -g pane-border-fg red
set-option -g pane-active-border-fg green
# message text
set-option -g message-bg default
set-option -g message-fg red
#bell
#set-window-option -g window-status-bell-style fg=black,bg=red
# Status left
# set -g status-left " [#S] "
# set -g status-left-length 50
# Custom status right
# set -g status-right "#[fg=color98] | [#(ifconfig eth0 | grep 'inet addr' | cut -d: -f2 | awk '{print $1}')] %d-%h-%Y %H:%M:%S |"
# Custom window format I - window number W - window name
# set-window-option -g window-status-current-format \
# "#{?window_zoomed_flag,#[bg=colour99]#[fg=colour232] [#I] \
# #[bg=colour235]#[fg=colour98] #W ^Z ,#[bg=colour99]#[fg=colour232] [#I] \
# #[bg=colour235]#[fg=colour98] #W } "
# set-window-option -g window-status-format \
# "#{?window_zoomed_flag,#[bg=colour239]#[fg=black] [#I] \
# #[bg=black]#[fg=green] #W ^Z ,#[bg=colour239]#[fg=black] [#I] \
# #[bg=black]#[fg=green] #W } "