Last active
January 14, 2025 16:16
-
-
Save mdalvi/9f1210733b21740792ac00ef4916f088 to your computer and use it in GitHub Desktop.
tmux configuration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Increase the scrollback buffer size from the default 2000 to 10000 lines | |
set-option -g history-limit 10000 | |
# Disable automatic window renaming | |
set-option -g allow-rename off | |
# Make tmux use 256 colors for better color rendering in terminal applications | |
set -g default-terminal "screen-256color" | |
# Change the default prefix key from 'Ctrl-b' to 'Ctrl-a' (more ergonomic) | |
unbind C-b | |
set-option -g prefix C-a | |
bind-key C-a send-prefix | |
# Start window numbering at 1 (easier to reach on keyboard) | |
set -g base-index 1 | |
# Enable mouse support (works in tmux 2.1 and above) | |
set -g mouse on | |
# Start pane numbering at 1 to match window numbering | |
set -g pane-base-index 1 | |
# Reload tmux configuration with 'prefix + r' | |
bind r source-file ~/.tmux.conf \; display "Configuration reloaded!" | |
# Switch panes using Alt-arrow without prefix (for quick navigation) | |
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 | |
# Enable vi-style navigation in copy mode | |
setw -g mode-keys vi | |
# Status bar customization for better visibility | |
set -g status-style bg=black,fg=white | |
set -g window-status-current-style bg=white,fg=black,bold | |
# Increase the speed of repeating commands (useful for resizing panes) | |
set -g repeat-time 1000 | |
# Set a longer display time for status messages | |
set -g display-time 2000 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Save this configuration to your ~/.tmux.conf file