89 lines
2.8 KiB
Text
89 lines
2.8 KiB
Text
|
|
# tmux configuration — managed by boma dev_env role (stow)
|
||
|
|
|
||
|
|
# Prefix
|
||
|
|
unbind C-b
|
||
|
|
set-option -g prefix C-a
|
||
|
|
bind-key C-a send-prefix
|
||
|
|
|
||
|
|
# General
|
||
|
|
set -g default-terminal "screen-256color"
|
||
|
|
set -ag terminal-overrides ",xterm-256color:RGB"
|
||
|
|
set -g mouse on
|
||
|
|
set -g history-limit 50000
|
||
|
|
set -g display-time 4000
|
||
|
|
set -g status-interval 5
|
||
|
|
set -g focus-events on
|
||
|
|
set -s extended-keys off
|
||
|
|
set -s set-clipboard on
|
||
|
|
set -g allow-passthrough on
|
||
|
|
set -as terminal-features ',xterm-256color:clipboard'
|
||
|
|
|
||
|
|
# Base index
|
||
|
|
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
|
||
|
|
|
||
|
|
# Vi mode in copy mode
|
||
|
|
set-window-option -g mode-keys vi
|
||
|
|
bind-key -T copy-mode-vi v send-keys -X begin-selection
|
||
|
|
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
|
||
|
|
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
|
||
|
|
|
||
|
|
# Splits — arrow direction = where new pane opens (mirrors kitty and nvim)
|
||
|
|
bind Right split-window -h -c "#{pane_current_path}"
|
||
|
|
bind Down split-window -v -c "#{pane_current_path}"
|
||
|
|
unbind '"'
|
||
|
|
unbind %
|
||
|
|
unbind v
|
||
|
|
unbind -
|
||
|
|
|
||
|
|
# Pane resize (repeatable)
|
||
|
|
bind -r H resize-pane -L 5
|
||
|
|
bind -r J resize-pane -D 5
|
||
|
|
bind -r K resize-pane -U 5
|
||
|
|
bind -r L resize-pane -R 5
|
||
|
|
|
||
|
|
# Window cycling — no prefix needed; mirrors nvim buffer cycling (Ctrl = inner layer)
|
||
|
|
bind -n C-Tab next-window
|
||
|
|
bind -n C-NPage next-window
|
||
|
|
bind -n C-PPage previous-window
|
||
|
|
|
||
|
|
# New window — t = tab (mirrors kitty Ctrl+Shift+T); keep c as alias
|
||
|
|
bind t new-window -c "#{pane_current_path}"
|
||
|
|
bind c new-window -c "#{pane_current_path}"
|
||
|
|
|
||
|
|
# Close pane without confirmation prompt
|
||
|
|
bind x kill-pane
|
||
|
|
|
||
|
|
# Reload config
|
||
|
|
bind r source-file ~/.tmux.conf \; display "Config reloaded!"
|
||
|
|
|
||
|
|
# =============================================================
|
||
|
|
# Plugins (TPM)
|
||
|
|
# Pin catppuccin to v1 API to avoid v2 breaking changes
|
||
|
|
# =============================================================
|
||
|
|
set -g @plugin 'tmux-plugins/tpm'
|
||
|
|
set -g @plugin 'tmux-plugins/tmux-sensible'
|
||
|
|
set -g @plugin 'christoomey/vim-tmux-navigator'
|
||
|
|
set -g @plugin 'catppuccin/tmux#v1.0.3'
|
||
|
|
|
||
|
|
# Catppuccin theme (v1 API)
|
||
|
|
set -g @catppuccin_flavour 'mocha'
|
||
|
|
set -g @catppuccin_window_left_separator ""
|
||
|
|
set -g @catppuccin_window_right_separator " "
|
||
|
|
set -g @catppuccin_window_middle_separator " █"
|
||
|
|
set -g @catppuccin_window_number_position "right"
|
||
|
|
set -g @catppuccin_window_default_fill "number"
|
||
|
|
set -g @catppuccin_window_current_fill "number"
|
||
|
|
set -g @catppuccin_window_current_text "#{pane_current_path}"
|
||
|
|
set -g @catppuccin_status_modules_right "directory session"
|
||
|
|
set -g @catppuccin_status_left_separator " "
|
||
|
|
set -g @catppuccin_status_right_separator ""
|
||
|
|
set -g @catppuccin_status_fill "icon"
|
||
|
|
set -g @catppuccin_status_connect_separator "no"
|
||
|
|
set -g @catppuccin_directory_text "#{pane_current_path}"
|
||
|
|
|
||
|
|
# Initialize TPM (keep at very bottom)
|
||
|
|
run '~/.tmux/plugins/tpm/tpm'
|