Skip to content

Instantly share code, notes, and snippets.

@abhirup-dev
Last active December 23, 2019 06:05
Show Gist options
  • Save abhirup-dev/262745d9d1816bca044f3a6721ef73a3 to your computer and use it in GitHub Desktop.
Save abhirup-dev/262745d9d1816bca044f3a6721ef73a3 to your computer and use it in GitHub Desktop.
unbind C-b
set -g prefix C-z
bind-key C-a send-prefix
# split panes using | and -
bind | split-window -h -c "#{pane_current_path}"
bind - split-window -v -c "#{pane_current_path}"
bind c new-window -c "#{pane_current_path}"
unbind '"'
unbind %
# switch panes using Alt-arrow without prefix
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
bind -n M-h select-pane -L
bind -n M-l select-pane -R
bind -n M-k select-pane -U
bind -n M-j select-pane -D
bind m resize-pane -Z
# reload config
# Enable mouse mode (tmux 2.1 and above)
set -g mouse on
######################
### DESIGN CHANGES ###
######################
# loud or quiet?
set -g visual-activity off
set -g visual-bell off
set -g visual-silence off
setw -g monitor-activity off
set -g bell-action none
## VI mode (https://sanctum.geek.nz/arabesque/vi-mode-in-tmux/)
set-window-option -g mode-keys vi
bind-key -T copy-mode-vi 'v' send -X begin-selection
bind-key -T copy-mode-vi 'y' send -X copy-selection-and-cancel
## Overriding copy-mode binding
bind -n 'PageUp' copy-mode
source-file ~/.tmux/plugins/tmux-themepack/basic.tmuxtheme
# List of plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'tmux-plugins/tmux-resurrect'
set -g @plugin 'tmux-plugins/tmux-continuum'
run-shell ~/.tmux/plugins/tmux-yank/yank.tmux
run-shell ~/.tmux/plugins/tmux-resurrect/resurrect.tmux
run-shell ~/.tmux/plugins/tmux-continuum/continuum.tmux
set -g @yank_with_mouse on
set -g @continuum-restore 'on'
run -b '~/.tmux/plugins/tpm/tpm'
# for vim
set -g @resurrect-strategy-vim 'session'
# for neovim
set -g @resurrect-strategy-nvim 'session'
@abhirup-dev
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment