Skip to content

Instantly share code, notes, and snippets.

@aileron
Created August 26, 2021 13:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aileron/d78d15ed866fe458878d47bb8ab52e73 to your computer and use it in GitHub Desktop.
Save aileron/d78d15ed866fe458878d47bb8ab52e73 to your computer and use it in GitHub Desktop.
set-option -g default-terminal screen-256color
# set-option -g default-command "reattach-to-user-namespace -l zsh"
set -g terminal-overrides 'xterm:colors=256'
set -g pane-border-status top
# Use vim keybindings in copy mode
setw -g mode-keys vi
# Setup 'v' to begin selection as in Vim
bind-key -T copy-mode-vi v send -X begin-selection
bind-key -T copy-mode-vi y send -X copy-pipe "reattach-to-user-namespace pbcopy"
# Update default binding of `Enter` to also use copy-pipe
unbind -T copy-mode-vi Enter
bind-key -T copy-mode-vi Enter send -X copy-pipe "reattach-to-user-namespace pbcopy"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment