Browse Source

Major tmux changes, also added project notes to the gitignore

master
Taylor Bockman 9 years ago
parent
commit
670fcbe59c
  1. 3
      dotfiles/global_gitignore
  2. 31
      dotfiles/tmux.conf

3
dotfiles/global_gitignore

@ -35,3 +35,6 @@ tramp
/smex-items /smex-items
/.smex-items /.smex-items
/smex-save-file /smex-save-file
# Notes file I tend to leave in projects
project-notes.org

31
dotfiles/tmux.conf

@ -7,13 +7,13 @@
# Rebind tmux prefix to <c-space> to match vim # Rebind tmux prefix to <c-space> to match vim
unbind-key C-b # remap prefix to Ctrl+A
set -g prefix Escape set -g prefix C-a
bind Escape send-prefix unbind C-b
bind-key C-a send-prefix
set -s escape-time 0 set -s escape-time 0
################################### ###################################
# # # #
# Colors # # Colors #
@ -49,22 +49,19 @@ set-window-option -g window-status-bell-style fg=black,bg=red #base02, red
bind Space copy-mode bind Space copy-mode
bind C-Space copy-mode bind C-Space copy-mode
# Rebind window splitting # Rebinds to be like neotree
# <prefix>j and <prefix>l split vertically and horizontally, respectively unbind %
bind j split-window -v bind | split-window -h
bind C-j split-window -v bind - split-window -v
bind l split-window -h
bind C-l split-window -h
# Smart pane switching with awareness of vim splits # Smart pane switching with awareness of vim splits
# This is the tmux side of the vim-tmux-navigator plugin # This is the tmux side of the vim-tmux-navigator plugin
is_vim='echo "#{pane_current_command}" | grep -iqE "(^|\/)g?(view|n?vim?)(diff)?$"' # is_vim='echo "#{pane_current_command}" | grep -iqE "(^|\/)g?(view|n?vim?)(diff)?$"'"
bind -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
bind -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D" bind -n M-Left select-pane -L
bind -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U" bind -n M-Right select-pane -R
bind -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R" bind -n M-Up select-pane -U
bind -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l" bind -n M-Down select-pane -D
# Vim keybinds so copy mode behaves more like vim # Vim keybinds so copy mode behaves more like vim
bind-key -t vi-copy 'v' begin-selection bind-key -t vi-copy 'v' begin-selection

Loading…
Cancel
Save