-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.tmux.conf
104 lines (82 loc) · 3.54 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
set-option -g status-position top
# Set indexing to be 1 based instead of 0 based (makes more sense for going through tabs, ie Chrome)
set -g base-index 1
setw -g mode-keys vi
setw -g aggressive-resize on
set -g status-keys emacs
# Set pane bindings to Vim movement
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
###########################################################################
# Mouse stuff!
# v2.2
set -g mouse on
###########################################################################
###########################################################################
# Resizing
# https://gist.github.com/spicycode/1229612
bind-key J resize-pane -D 5
bind-key K resize-pane -U 5
bind-key H resize-pane -L 5
bind-key L resize-pane -R 5
bind-key M-j resize-pane -D 1
bind-key M-k resize-pane -U 1
bind-key M-h resize-pane -L 1
bind-key M-l resize-pane -R 1
# Full screen
bind-key Z resize-pane -Z
###########################################################################
# Reload tmux config
bind r source-file ~/.tmux.conf
# Clear the screen
bind-key b send-keys -R \; clear-history
# Increase history size
set -g history-limit 5000
# change the default timeout
# http://www.muddygoat.org/articles/vim-in-tmux
set -sg escape-time 0
# from alex@dailyjs https://gist.github.com/alexyoung/6040385
set -g status on
# 12 hour clock
set -g clock-mode-style 12
set-window-option -g clock-mode-style 12
# tmux-online-status
set -g @online_icon "●"
set -g @offline_icon "○"
bind m set -g status-right '#[fg=colour052,bold] #(~/bin/now-playing.sh) #{battery_icon_status} #{battery_percentage} #{online_status} #[fg=colour052,nobold] %Y.%m.%d %I:%M:%S%p '
bind M set -g status-right '#[fg=colour052,bold] #{battery_icon_status} #{battery_percentage} #{online_status} #[fg=colour052,nobold] %Y.%m.%d %I:%M:%S%p '
set -g status-right '#[fg=colour052,bold] #{battery_icon_status} #{battery_percentage} #{online_status} #[fg=colour052,nobold] %Y.%m.%d %I:%M:%S%p '
set -g status-right-length 200
set -g status-left '#[fg=colour241]#S '
set -g status-bg "colour178"
set -g window-status-format "#[fg=colour241] #I #[fg=colour241]#W #[fg=colour31]"
set -g window-status-current-format "#[fg=colour052,bg=colour220] #I #[fg=colour052,bold]#W #[fg=colour31,bg=colour234,nobold]"
# http://superuser.com/questions/517402/force-update-for-tmux-status-bar
set -g status-interval 1
# Make current path the default
bind '"' split-window -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
bind c new-window -c "#{pane_current_path}"
# https://github.com/NHDaly/tmux-scroll-copy-mode
set -g @scroll-speed-num-lines-per-scroll "1"
# run-shell ~/.tmux/scroll-copy-mode/scroll_copy_mode.tmux
# https://superuser.com/questions/480809/updating-window-indexes-with-tmux
set-option -g renumber-windows on
# https://github.com/roxma/vim-tmux-clipboard
set -g focus-events on
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'tmux-plugins/tmux-open'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-battery'
set -g @plugin 'tmux-plugins/tmux-online-status'
set -g @plugin 'b0o/tmux-autoreload'
# https://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard/issues/8#issuecomment-37170747
if-shell 'test "$(uname)" = "Darwin"' 'source ~/dotfiles/tmux.osx'
if-shell 'test "$(uname)" = "Linux"' 'source ~/dotfiles/tmux.linux'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'