Files
dotfiles/.config/tmux/tmux.conf

40 lines
1.0 KiB
Bash

# Set true color
set-option -sa terminal-overrides ",xterm*:Tc"
# Enable Mouse
set -g mouse on
# Start windows and panes at 1, not 0
set -g base-index 1
set -g pane-base-index 1
set-window-option -g pane-base-index 1
set-option -g renumber-windows on
# Set prefix
unbind C-b
set -g prefix C-Space
bind C-Space send-prefix
# Plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'christoomey/vim-tmux-navigator'
set -g @plugin 'dreamsofcode-io/catppuccin-tmux'
set -g @plugin 'tmux-pligins/tmux-yank'
# set vi-mode
set-window-option -g mode-keys vi
# keybinings
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectagle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
# Open panes in current directory
bind '"' split-window -v -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
# if run as "tmux attach", create a session if one does not already exist
new-session -n $HOST
run '~/.tmux/plugins/tpm/tpm'