-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
66 lines (50 loc) · 1.77 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
set -g default-command zsh
# Plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'jimeh/tmux-themepack'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'tmux-plugins/tmux-battery'
# Theme
set -g @themepack 'default/cyan'
# Enable true color
# https://gist.github.com/andersevenrud/015e61af2fd264371032763d4ed965b6
set -g default-terminal xterm-256color
set -ag terminal-overrides ",xterm-256color:RGB"
# Increase history size
set -g history-limit 10000
# Mouse mode
set -g mouse on
# Smooth scrolling
bind -T copy-mode-vi WheelDownPane send -X scroll-down
bind -T copy-mode-vi WheelUpPane send -X scroll-up
# Handle platform-dependent copying in a seperate script
bind -T copy-mode-vi MouseDragEnd1Pane send -X copy-pipe "bash -c '\
$(dirname $(readlink $HOME/.tmux.conf))/scripts/tmux-cbcopy.sh\
'"
# vi bindings in copy mode
set -g mode-keys vi
# vim style pane selection
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Shift arrow to switch windows
bind -n S-Left previous-window
bind -n S-Right next-window
# Ctrl Shift arrow to move windows
bind -n C-S-Left swap-window -d -t -1
bind -n C-S-Right swap-window -d -t +1
# Reload tmux config
bind r source-file ~/.tmux.conf
# Copy over pane paths
bind '"' split-window -v -c "#{pane_current_path}"
bind '%' split-window -h -c "#{pane_current_path}"
# Start window numbers from 1
set -g base-index 1
# Include battery in status bar
set -g @batt_remain_short true
set -g @themepack-status-right-area-left-prefix '#{battery_percentage} #{battery_icon} #{battery_remain} '
set -g @themepack-status-right-area-left-format '%I:%M %p'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'