Created
February 8, 2017 17:17
-
-
Save cevaris/edefa2624cd21093aeb30a235fe4eb4a to your computer and use it in GitHub Desktop.
tmux 2.4 conf
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
set-option -g default-shell /bin/zsh | |
set-option -g default-command "reattach-to-user-namespace -l zsh" | |
set -g default-terminal "screen-256color" | |
set -g base-index 1 | |
# Override default prefix | |
unbind C-b | |
set -g prefix C-t | |
bind C-t send-prefix | |
# Preserve directory on split/new pane/window | |
bind-key % split-window -h -c "#{pane_current_path}" | |
bind-key \ split-window -h -c "#{pane_current_path}" | |
bind-key '"' split-window -c "#{pane_current_path}" | |
bind-key - split-window -c "#{pane_current_path}" | |
bind-key c new-window -c "#{pane_current_path}" | |
# Mouse scrolling | |
# setw -g mode-mouse on | |
# set -g mouse-select-pane on | |
# set -g mouse-resize-pane on | |
# set -g mouse-select-window on | |
set -g terminal-overrides 'xterm*:smcup@:rmcup@' | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
set -g history-limit 1000000 | |
# set-window-option -g mode-keys vi | |
# Mark/color active pane | |
set -g pane-border-style fg=magenta | |
set -g pane-active-border-style fg=magenta | |
set -g pane-active-border-style bg=default | |
# Pane slection | |
bind h select-pane -L | |
bind j select-pane -D | |
bind k select-pane -U | |
bind l select-pane -R | |
# Resizing panes | |
bind-key C-h resize-pane -L 15 | |
bind-key C-j resize-pane -D 15 | |
bind-key C-k resize-pane -U 15 | |
bind-key C-l resize-pane -R 15 | |
# Copy & Paste | |
setw -g mode-keys emacs | |
bind-key -T copy-mode [ send -X begin-selection | |
bind-key -T copy-mode M-w send -X copy-pipe "reattach-to-user-namespace pbcopy" | |
unbind -T copy-mode Enter | |
bind-key -T copy-mode Enter send -X copy-pipe "reattach-to-user-namespace pbcopy" | |
# Reload tmux config | |
bind-key a source-file ~/.tmux.conf | |
# # move x clipboard into tmux paste buffer | |
# bind C-w run "tmux set-buffer \"$(xclip -o)\"; tmux paste-buffer" | |
# # move tmux copy buffer into x clipboard | |
# bind C-y run "tmux show-buffer | xclip -i" | |
#new -n tmux | |
#selectw -t 1 | |
set -g @plugin 'tmux-plugins/tmux-resurrect' | |
run-shell /git/tmux-resurrect/resurrect.tmux |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment