-
Notifications
You must be signed in to change notification settings - Fork 6
/
tmux.conf
112 lines (88 loc) · 3.61 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
108
109
110
111
112
# Scott Stanfield
source-file ~/.tmux.reset.conf
set-option -g default-terminal 'tmux-256color'
set-option -g terminal-overrides ",*:RGB"
set -g prefix ^o # use ctrl-o as our <leader>
bind C-o send-prefix
unbind-key C-b # pass ctrl-o down to other apps
set -g base-index 1 # start indexing windows at 1 instead of 0
set -g detach-on-destroy off # don't exit from tmux when closing a session
set -g escape-time 0 # zero-out escape time delay
set -g history-limit 1000000 # increase history size (from 2,000)
set -g renumber-windows on # renumber all windows when any window is closed
set -g set-clipboard on # use system clipboard
set -g status-position bottom # show tmux status on top
#set -g default-terminal "${TERM}" # default wants to open zsh
set -g default-command "${SHELL}" # tmux spawns a login shell by default resulting in negative side effects
# set -g allow-rename off # don't let tmux rename our windows in the status bar
# set -g set-titles off
# set -g detatch-on-destroy off
setw -g mode-keys vi # prefix + [ (then vim nav, space highlight, yank, enter)
set -g pane-active-border-style 'fg=magenta,bg=default'
set -g pane-border-style 'fg=brightblack,bg=default'
set -g @fzf-url-fzf-options '-p 60%,30% --prompt=" " --border-label=" Open URL "'
set -g @fzf-url-history-limit '2000'
# tmux 3.2
# set -as terminal-features ",xterm-256color:RGB"
# set -as terminal-features ",alacritty:RGB"
set -g mouse on
# terminal-overrides applies to the outside $TERM. It basically
# says: When starting tmux in a shell that has $TERM set to
# xterm-256color, add the Tc capability to tmux’s internal image
# of tmux-256color to signalize it to use true colors.
#####################
# random key bindings
#####################
unbind r
bind r source-file ~/.tmux.conf \; display "Reloaded ~/.tmux.conf"
bind , command-prompt "rename-window %%"
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# switch panes using Alt-arrow without prefix
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Rebind pane tiling to sane mnemonics and start
# new window in same directory from where you are now.
bind v split-window -h -c "#{pane_current_path}"
bind s split-window -c "#{pane_current_path}"
bind | split-window -h -c "#{pane_current_path}"
bind - split-window -v -c "#{pane_current_path}"
unbind '"'
unbind %
# pane resizing
bind H resize-pane -L 5
bind J resize-pane -D 5
bind K resize-pane -U 5
bind L resize-pane -R 5
bind < resize-pane -L 5
bind + resize-pane -D 5
bind - resize-pane -U 5
bind > resize-pane -R 5
# quick pane cycling (ctrl-o twice quickly)
unbind ^O; bind ^O select-pane -t :.+
# Fix clear screen
bind C-l send-keys 'C-l'
# Fix yank
bind C-k send-keys 'C-k'
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-yank' # prefix-y
#set -g @plugin 'omerxx/tmux-session-manager'
#set -g @plugin 'omerxx/catppuccin-tmux'
#set -g @catppuccin_window_current_text "#W#{?window_zoomed_flag,(Z),}"
tm_icon=
tm_icon=☉
tm_icon=$HOST_ICON
set -g @plugin 'dracula/tmux'
set -g @dracula-show-powerline false
set -g @dracula-show-timezone false
set -g @dracula-show-border-contrast true
set -g @dracula-show-left-icon $tm_icon
set -g @dracula-left-icon-padding 1
# # available plugins: battery, cpu-usage, git, gpu-usage, ram-usage, network, network-bandwidth, network-ping, weather, time
set -g @dracula-plugins "ssh-session time"
run '~/.tmux/plugins/tpm/tpm'