-
Notifications
You must be signed in to change notification settings - Fork 0
/
.tmux.conf
68 lines (49 loc) · 1.78 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
##################
# Base Changes #
##################
# remap prefix from 'C-b' to 'C-o'
unbind C-b
set-option -g prefix C-o
bind-key C-o send-prefix
# split panes using \ and -
bind '\' split-window -h
bind - split-window -v
unbind '"'
unbind %
# setting the default shell of tmux to be zsh
# TODO: Avoid using the hardcoded full path of zsh
set-option -g default-shell /bin/zsh
# reload config file (change file location to your the tmux.conf you want to use)
bind r source-file ~/.tmux.conf
# Enable mouse control (clickable windows, panes, resizable panes)
set -g mouse on
# pane navigation to match Vi directions
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# don't rename windows automatically
set-option -g allow-rename off
##################
# Plugins #
##################
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
set -g @continuum-restore 'on'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'nhdaly/tmux-better-mouse-mode'
set -g @scroll-speed-num-lines-per-scroll 1
set -g @plugin 'erikw/tmux-powerline'
###########################################
# Initializing TPM and Installing Plugins #
###########################################
# Set the PATH variable to ensure all tools installed via Homebrew are accessible
set-environment -g PATH "/opt/homebrew/bin:$PATH"
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run-shell '~/.tmux/plugins/tpm/tpm'
# Automatically download TPM plugins if not available
if "test ! -d ~/.tmux/plugins/tpm" \
"run 'git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm'"
# Install plugins if not already installed
run-shell '~/.tmux/plugins/tpm/bin/install_plugins'