-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
107 lines (86 loc) · 2.92 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
# zsh is kinda tight
set-option -g default-shell $SHELL
set-option -g default-command "reattach-to-user-namespace -l zsh"
set -g default-terminal "screen-256color"
# Set auto renaming of windows off
set-option -g allow-rename off
# shorten command delay
set -sg escape-time 1
set -g history-limit 100000
# act like GNU screen
unbind C-b
set -g prefix C-Space
bind Space send-prefix
# set -g prefix C-a
# Use m to toggle mouse mode
# unbind m
# bind m setw mouse
# a mouse
# set -g mode-mouse on
# setw -g mouse-select-window on
# setw -g mouse-select-pane on
# Select Panels
setw -g mode-keys vi
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Switches panel and zooms without losing zoom
bind -r a select-pane -t .+1 \; resize-pane -Z
# resize panes using PREFIX H, J, K, L
bind H resize-pane -L 10
bind J resize-pane -D 10
bind K resize-pane -U 10
bind L resize-pane -R 10
# Use C-h and C-l to cycle windows
bind-key C-h select-window -t :-
bind-key C-l select-window -t :+
# Refresh
bind-key r source-file ~/.tmux.conf
# copy and paster
unbind [
bind ` copy-mode
unbind p
bind -n C-k send-keys -R \; clear-history
# # bind -n C-k clear-history
# bind C-k clear-history
bind p paste-buffer
bind-key -T copy-mode-vi v send -X begin-selection
bind-key -T copy-mode-vi y send -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy"
# after copying to a tmux buffer, hit y again to copy to clipboard
bind y run "tmux save-buffer - | reattach-to-user-namespace pbcopy"
# ----------------------
# set some pretty colors
# ----------------------
# set pane colors - highlight the active pane
# set-option -g pane-border-fg colour15 #base02
# set-option -g pane-active-border-fg colour12 #base01
set -g pane-border-style fg=colour15
set -g pane-active-border-style fg=colour12
# colorize messages in the command line
# set-option -g message-bg black
# set-option -g message-fg brightred
set -g message-style fg=brightred,bg=black
# ----------------------
# Status Bar
# -----------------------
set -g status-interval 5 # set update frequencey (default 15 seconds)
set -g status-justify centre # center window list for clarity
# set-option -g status-position top # position the status bar at top of screen
# visual notification of activity in other windows
setw -g monitor-activity off
set -g visual-activity off
# set color for status bar
set-option -g status-bg default
set-option -g status-fg colour5
# set-option -g status-attr dim
set -g status-style default
# show session name, window & pane number,
# date and time on right side of status bar
set -g status-right-length 50
set -g status-left "#[fg=colour39]#S"
set -g status-right "#[fg=colour39]%a, %d %b %Y, #(date -u '+%%H:%%M') (%H:%M %Z)"
set -g window-status-format "#[fg=white,bg=default] #I #W "
set -g window-status-current-format "#[fg=colour17,bg=colour39,noreverse] #I #W "
# scrolling
set -g terminal-overrides 'xterm*:smcup@:rmcup@'