tmux only shared variant (#3)
Reviewed-on: #3 Co-authored-by: Tomas Mirchev <contact@tomastm.com> Co-committed-by: Tomas Mirchev <contact@tomastm.com>
This commit was merged in pull request #3.
This commit is contained in:
@@ -1,70 +1,58 @@
|
||||
# Change the prefix from 'C-b' to 'C-Space'
|
||||
##### Prefix #####
|
||||
unbind C-b
|
||||
set-option -g prefix C-Space
|
||||
bind-key C-Space send-prefix
|
||||
set -g prefix C-Space
|
||||
bind C-Space send-prefix
|
||||
|
||||
set-option -g set-clipboard on
|
||||
##### General #####
|
||||
set -s default-terminal "tmux-256color"
|
||||
set -s escape-time 10
|
||||
set -s focus-events on
|
||||
set -s set-clipboard on
|
||||
|
||||
#set -g default-terminal "tmux-256color"
|
||||
#set -as terminal-features ",*:RGB"
|
||||
set-option -a terminal-features 'xterm-256color:RGB'
|
||||
set-option -sg escape-time 10
|
||||
set-option -g repeat-time 0
|
||||
set-option -g focus-events on
|
||||
|
||||
# Set the base index for windows and panes to 1 instead of 0
|
||||
set -g base-index 1
|
||||
setw -g pane-base-index 1
|
||||
|
||||
# Increase scrollback buffer size
|
||||
set -g base-index 1 # window index
|
||||
set -g renumber-windows on # window index
|
||||
set -g history-limit 10000
|
||||
set -g repeat-time 0
|
||||
set -g mouse on
|
||||
set -g set-titles on
|
||||
set -g set-titles-string "#S"
|
||||
|
||||
# Customize the status bar for Catppuccin Latte
|
||||
set -g status-style bg=default,fg='#4c4f69' # Catppuccin Latte text color
|
||||
set -g status-left '#[fg=#1e66f5,bold][#S] ' # Catppuccin Latte blue for session
|
||||
set -gw pane-base-index 1 # pane index
|
||||
set -gw synchronize-panes on
|
||||
|
||||
##### Appearance #####
|
||||
set -g status-style fg=black,bg=default
|
||||
set -g window-status-current-style fg=blue,bold
|
||||
set -g message-style fg=blue,bg=default
|
||||
set -g status-left "#[fg=blue,bold][#S] "
|
||||
set -g status-right "host:#H | machine:#{?TARGET_MACHINE,#{TARGET_MACHINE},local}"
|
||||
set -g status-left-length 50
|
||||
set -g status-right ''
|
||||
set -g status-right-length 50
|
||||
set -g pane-active-border-style fg=blue
|
||||
|
||||
# Optional: Style the window tabs to match
|
||||
set -g window-status-current-style 'fg=#4c4f69,bold' # Active window - dark text, bold
|
||||
set -g window-status-style 'fg=#6c6f85' # Inactive windows - lighter text
|
||||
set -g window-status-separator ' | ' # Clean separator
|
||||
|
||||
# Optional: Style the borders to match (if you use pane borders)
|
||||
set -g pane-border-style 'fg=#ccd0da' # Light border for inactive panes
|
||||
set -g pane-active-border-style 'fg=#1e66f5' # Blue border for active pane
|
||||
|
||||
set -g status-left-length 20
|
||||
set -g status-right-length 20
|
||||
set -g pane-border-format ""
|
||||
# Message text
|
||||
set -g message-style bg=default,fg=cyan
|
||||
|
||||
# Enable mouse support
|
||||
setw -g mouse on
|
||||
|
||||
# Fix scroll. Use N3 instead of N1 to make it quicker
|
||||
bind-key -T copy-mode-vi WheelUpPane send -N1 -X scroll-up
|
||||
bind-key -T copy-mode-vi WheelDownPane send -N1 -X scroll-down
|
||||
|
||||
# Update terminal titles
|
||||
set-option -g set-titles on
|
||||
set-option -g set-titles-string "#S"
|
||||
|
||||
# Use vim keybindings in copy mode
|
||||
setw -g mode-keys vi
|
||||
|
||||
# Setup 'v' to begin selection as in Vim
|
||||
##### Vim-like #####
|
||||
set -gw mode-keys vi
|
||||
bind -T copy-mode-vi v send-keys -X begin-selection
|
||||
|
||||
# Pane navigation using vim-like keys
|
||||
bind -r k select-pane -U
|
||||
bind -r j select-pane -D
|
||||
bind -T copy-mode-vi WheelUpPane send -N1 -X scroll-up
|
||||
bind -T copy-mode-vi WheelDownPane send -N1 -X scroll-down
|
||||
bind -r h select-pane -L
|
||||
bind -r j select-pane -D
|
||||
bind -r k select-pane -U
|
||||
bind -r l select-pane -R
|
||||
|
||||
# Automatically renumber windows when one is closed
|
||||
set -g renumber-windows on
|
||||
unbind '"'
|
||||
unbind "%"
|
||||
unbind s
|
||||
unbind c
|
||||
unbind n
|
||||
unbind x
|
||||
|
||||
# Reload tmux config
|
||||
bind s split-window -v -c "#{pane_current_path}"
|
||||
bind v split-window -h -c "#{pane_current_path}"
|
||||
bind o choose-session
|
||||
bind n new-window
|
||||
bind c confirm-before -p "kill-pane \#P? (y/n)" kill-pane
|
||||
|
||||
##### Misc #####
|
||||
bind r source-file ~/.tmux.conf \; display "Reloaded!"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user