-
Notifications
You must be signed in to change notification settings - Fork 0
/
tmux.conf
88 lines (68 loc) · 2.32 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
# Use C-a instead of C-b, because
# of muscle memory from GNU screen.
set -g prefix C-a
bind-key C-a last-window
# Cycle through panes
bind-key Tab select-pane -t :.+
# when there are multiple clients for the same session and
# the window sizes are different
setw -g aggressive-resize on
# faster command sequences
set -s escape-time 0
# Report that we can handle 256 colors
set -g default-terminal "screen-256color"
setw -g xterm-keys on
# Allow history scrollback up to 5000 lines
set -g history-limit 5000
# Use zsh
set -g default-command /bin/zsh
set -g default-shell /bin/zsh
# vim-style navigation
setw -g mode-keys vi
unbind-key j
bind-key j select-pane -D
unbind-key k
bind-key k select-pane -U
unbind-key h
bind-key h select-pane -L
unbind-key l
bind-key l select-pane -R
# '0' is at the wrong end of the keyboard
set -g base-index 1
set -g pane-base-index 1
# # Toggle mouse mode on and off.
# # With mouse mode on, you can do copies within the tmux buffer.
# bind m \
# setw -g mouse on \;\
# display 'Mouse: ON'
# # With mouse mode OFF, you can do copies with in the OS buffer.
# bind M \
# setw -g mouse off \;\
# display 'Mouse: OFF'
# Go to marked pane
# Commenting out for now. Stopped working in tmux 3.3a
# bind 1 select-pane -t {marked}
# I like to give my windows descriptive names
set-window-option -g automatic-rename off
# Allow longer tmux session names
set -g status-left-length 100
# Toggle sending keystrokes to all panes in a window
bind-key a set-window-option synchronize-panes
# Set bg color for current pane.
set-window-option -g window-status-current-style bg=white
# forward ssh agent to tmux session
# set-environment -g 'SSH_AUTH_SOCK' ~/.ssh/ssh_auth_sock
# set -g update-environment "DISPLAY SSH_ASKPASS SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY"
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-battery'
set -g @plugin 'tmux-plugins/tmux-resurrect'
# show battery info
set -g status-right '#{battery_icon} #{battery_percentage} #{battery_remain} | %H:%M '
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
# You'll need to have a local fork of tpm in your machine...
#
# git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
#
# Then once tmux is up, enter `C-a I` to install the tmux plugins:
run '~/.tmux/plugins/tpm/tpm'