Created
December 25, 2016 03:23
-
-
Save shreve/4b616a221b682f5a91ad0b5c0b4d845f 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
set -g prefix C-a | |
set -g default-terminal "screen-256color" | |
set -g default-command "reattach-to-user-namespace fish" | |
bind C-a send-prefix | |
unbind C-b | |
# Set lines of history to scrollback | |
set -g history-limit 3000 | |
# Make shift+arrows, ctrl+arrows etc work in Vim. | |
set -g xterm-keys on | |
# Start window and pane indices at 1. | |
set -g base-index 1 | |
set -g pane-base-index 1 | |
# Status bar styling and content. | |
set -g status-bg colour0 | |
set -g status-fg white | |
set -g status-left '' | |
set -g status-right '#(tmux-line)' | |
set -g status-interval 3 | |
# Highlight the active window in the status bar. | |
set-window-option -g window-status-current-bg green | |
set-window-option -g window-status-current-fg black | |
# Don't prompt to kill panes/windows. | |
bind-key x kill-pane | |
bind-key X kill-window | |
# Make panes equal sizes | |
# bind-key = select-layout even-vertical; select-layout even-horizontal | |
# Cycle panes. | |
bind a select-pane -t :.+ | |
bind C-a select-pane -t :.+ | |
# Reload tmux conf. | |
unbind r | |
bind r source-file ~/.tmux.conf\; display "Reloaded conf." | |
# Open new panes and windows in current directory | |
bind % split-window -h -c "#{pane_current_path}" | |
bind '"' split-window -c "#{pane_current_path}" | |
bind c new-window -c "/Users/jacob/sync/inbox" | |
# Rearrange and resize panes | |
unbind = | |
bind-key = select-layout main-vertical; | |
bind-key _ select-layout main-horizontal; | |
bind-key + resize-pane -R 5; | |
bind-key - resize-pane -L 5; | |
# http://robots.thoughtbot.com/tmux-copy-paste-on-os-x-a-better-future | |
# Use vim keybindings in copy mode | |
setw -g mode-keys vi | |
# Setup 'v' to begin selection as in Vim | |
bind-key -t vi-copy v begin-selection | |
bind-key -t vi-copy y copy-pipe "reattach-to-user-namespace pbcopy" | |
# Update default binding of `Enter` to also use copy-pipe | |
unbind -t vi-copy Enter | |
bind-key -t vi-copy Enter copy-pipe "reattach-to-user-namespace pbcopy" | |
# Renumber windows when one is deleted | |
set-option -g renumber-windows on |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment