Created
January 27, 2023 22:45
-
-
Save fernandotakai/2ded0cb48cb8d9c591ae9cddfb04a480 to your computer and use it in GitHub Desktop.
This file contains 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
# everything gets better with vim bindings | |
setw -g mode-keys vi | |
unbind [ | |
bind '[' copy-mode | |
unbind p | |
bind p paste-buffer | |
bind-key -T copy-mode-vi v send-keys -X begin-selection | |
# Update default binding of `Enter` to also use copy-pipe | |
unbind -T copy-mode-vi Enter | |
bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "/home/ftakai/bin/copy-stuff" | |
bind > run "( tmux show-buffer | xsel) && tmux display-message \"ok!\"" | |
# we want color ffs | |
set -g default-terminal "tmux-256color" | |
set-option -sa terminal-overrides ',alacritty:RGB' | |
set-option -g focus-events on | |
# we also want mouse | |
set -g mouse on | |
unbind C-b | |
set -g prefix C-x | |
set-option -g allow-rename off | |
set-option -g renumber-windows on | |
set-option -g repeat-time 200 | |
set-option -g history-limit 10000 | |
# moving window easy way | |
bind-key m command-prompt -p "move window to:" "swap-window -t '%%'" | |
bind C new-window -c "#{pane_current_path}" | |
# not-so-easy to type, but easier to remember | |
unbind % | |
bind | split-window -h -c "#{pane_current_path}" | |
bind - split-window -v -c "#{pane_current_path}" | |
# change windows | |
bind h select-pane -L | |
bind j select-pane -D | |
bind k select-pane -U | |
bind l select-pane -R | |
# resize panes | |
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 | |
bind q last-window | |
set-option -sg escape-time 10 | |
source "/usr/lib/python3.10/site-packages/powerline/bindings/tmux/powerline.conf" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment