-
Notifications
You must be signed in to change notification settings - Fork 0
/
tmux.conf
executable file
·97 lines (76 loc) · 2.96 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
# use UTF8
set -g utf8
set-window-option -g utf8
# Set terminal to 256 Color by default
set -g default-terminal "xterm"
# shorted command delay
set -sg escape-time 1
# Set prefix toe Ctrl-a
set -g prefix C-a
unbind C-b
# History to 30k
set -g history-limit 30000
# Set split keys
unbind %
bind \ split-window -h
bind - split-window -v
# Set movement between panes
bind-key k select-pane -U
bind-key j select-pane -D
bind-key h select-pane -L
bind-key l select-pane -R
# Resize Panes
bind H resize-pane -L 5
bind J resize-pane -D 5
bind K resize-pane -U 5
bind L resize-pane -R 5
# Reload ~/.tmux.conf using prefix r
bind r source-file ~/.tmux.conf \; display "Reloaded!"
# highlight active pane
set-option -g pane-border-fg colour235 #base02
set-option -g pane-active-border-fg colour240
# colorize messages in command line
set-option -g message-bg black #base-02
set-option -g message-fg brightred #orange
# ----------------------
# Status bar
# ----------------------
set-option -g status on
set -g status-utf8 on
set -g status-interval 5
set -g status-interval 5
set -g status-justify centre
# visual notification of activity in other windows
setw -g monitor-activity on
set -g visual-activity on
# set color for status bar
set-option -g status-bg colour235 #base02
set-option -g status-fg yellow #yellow
set-option -g status-attr dim
# set window list colors - red for active and cyan for inactive
set-window-option -g window-status-fg brightblue #base0
set-window-option -g window-status-bg colour236
set-window-option -g window-status-attr dim
set-window-option -g window-status-current-fg brightred #orange
set-window-option -g window-status-current-bg colour236
set-window-option -g window-status-current-attr bright
# show host name and IP address on left side of status bar
set -g status-left-length 85
#set -g status-left "#[fg=green]: #h : #[fg=brightblue]#(curl icanhazip.com) #[fg=yellow]#(ifconfig en0 | grep 'inet ' | awk '{print \"en0 \" $2}') #(ifconfig en1 | grep 'inet ' | awk '{print \"en1 \" $2}') #(ifconfig en3 | grep 'inet ' | awk '{print \"en3 \" $2}') #[fg=red]#(ifconfig tun0 | grep 'inet ' | awk '{print \"vpn \" $2}') #[fg=green]#(/System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -I | awk -F': ' '/ SSID/{print $2}') "
# show session name, window & pane number, date and time on right side of
# status bar
set -g status-right-length 80
set -g status-right "#[fg=cyan]#{=15:pane_title} : #[fg=blue]#S #I:#P #[fg=yellow]: %d %b %Y #[fg=green]: %l:%M %p : #(date -u | awk '{print $4}') :"
# ------------------
# Copy & Paste
# ------------------
# Access to clipboard
set-window-option -g automatic-rename on
# use vim keybindings in copy mode
setw -g mode-keys vi
# bind v as begin selection
bind-key -t vi-copy v begin-selection
bind-key -t vi-copy y copy-pipe 'xclip -in -selection clipboard'
# Update default binding Enter to also use copy-pipe
unbind -t vi-copy Enter
bind-key -t vi-copy Enter copy-pipe 'xclip -in -selection clipboard'