Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Change keybindings/style based off of aziz dotfies.

  • Loading branch information...
commit e92066775fe2efaad33581c9a6c67ce555d8d949 1 parent fd76640
@zolrath authored
Showing with 81 additions and 51 deletions.
  1. +81 −51 tmux.conf
View
132 tmux.conf
@@ -1,35 +1,56 @@
-# specify the name of your tmux socket with -S when creating it
-# tmux -S /tmp/pair
-# chmod to allow other users to access it
-# chmod 777 /tmp/pair
-# now the other user can connect with
-# tmux -S /tmp/pair attach
-
# Make pasteboard in OS X work.
set -g default-command "reattach-to-user-namespace -l zsh"
-# Make it use C-a, similar to screen.
+## keybindings
unbind C-b
-# C-a C-a to go to last window.
+unbind C-a
+unbind %
+unbind , #
+unbind .
+unbind n
+unbind p
+unbind [
+unbind '"'
+unbind h
+unbind j
+unbind k
unbind l
-set -g prefix C-a
-bind-key C-a last-window
-# Make window numbers start at 1 instead of 0.
-set -g base-index 1
-setw -g aggressive-resize on
-# Mouse can be used to select/resize windows and panes.
-set -g mode-mouse on
-set -g mouse-select-pane on
-set -g mouse-select-window on
-set -g mouse-utf8 on
+unbind Left
+unbind Right
+unbind Down
+unbind Up
+unbind &
+unbind "'"
-# Turn off automatic window renaming to keep tmuxinator titles.
-setw -g automatic-rename off
+set-option -g prefix C-a # C-a for prefix just like screen
-# Change splitting windows to easier to remember _ and |
-unbind % # Remove default binding since we’re replacing
+bind C-a last-window
bind | split-window -h
+bind \ split-window -h
bind _ split-window -v
+bind x kill-pane
+bind X kill-window
+bind q confirm-before kill-session
+bind Q confirm-before kill-server
+# -r flag allows repeated use without sending command sequence again.
+bind -r , previous-window # <
+bind -r . next-window # >
+bind -r < swap-window -t :-
+bind -r > swap-window -t :+
+bind n command-prompt 'rename-window %%'
+bind N command-prompt 'rename-session %%'
+bind Escape copy-mode -u
+bind C-r source-file ~/.tmux.conf; display-message " ✱ ~/.tmux.conf is reloaded"
+bind R refresh-client
+bind a send-key C-a
+bind -r Left resize-pane -L 2
+bind -r Right resize-pane -R 2
+bind -r Down resize-pane -D 2
+bind -r Up resize-pane -U 2
+bind j select-pane -D # Similar to 'C-w j' to navigate windows in Vim
+bind k select-pane -U
+bind h select-pane -L
+bind l select-pane -R
# Zoom in one current pane.
unbind +
@@ -39,32 +60,16 @@ bind - last-window \; swap-pane -s tmux-zoom.0 \; kill-window -t tmux-zoom
# I'm a Vim user, this makes navigation easier
setw -g mode-keys vi # I especially like being able to search with /,? when in copy-mode
-unbind j
-unbind k
-unbind h
-unbind l
-bind j select-pane -D # Similar to 'C-w j' to navigate windows in Vim
-bind k select-pane -U
-bind h select-pane -L
-bind l select-pane -R
-
-# resize pane with arrow keys
-# -r: can be repeated without pressing prefix
-# again (500ms after last '-r' action or prefix)
-unbind Left
-unbind Right
-unbind Down
-unbind Up
-bind -r Left resize-pane -L 2
-bind -r Right resize-pane -R 2
-bind -r Down resize-pane -D 2
-bind -r Up resize-pane -U 2
-# quit
-bind-key \ confirm-before kill-server
+# Mouse can be used to select/resize windows and panes.
+set -g mode-mouse on
+set -g mouse-select-pane on
+set -g mouse-select-window on
+set -g mouse-utf8 on
-# Reload key
-bind r source-file ~/.tmux.conf
+# Make window numbers start at 1 instead of 0.
+set -g base-index 1
+setw -g aggressive-resize on
set -g history-limit 1000
@@ -76,7 +81,32 @@ set -g visual-activity on
set -g status-bg black
set -g status-fg white
set -g status-interval 60
-set -g status-left-length 30
-set -g status-left '#[fg=green](#S) #(whoami)@#H#[default]'
-set -g status-right '#[fg=yellow]#(cut -d -f 1-3 /proc/loadavg)#[default] #[fg=blue]%H:%M#[default]'
-set-window-option -g window-status-current-bg blue
+
+set-option -g status-left ' #[bold]❐ #S#[default] ⡇'
+set-option -g status-right '#[bold]#(whoami) ● #H#[default] ⣿ #[fg=blue]%H:%M#[default]'
+
+set-option -g status-right-length 60
+set-option -g status-left-length 60
+
+## highlight active window
+set-window-option -g window-status-current-bg colour148
+set-window-option -g window-status-current-fg colour23
+set-window-option -g window-status-current-attr bold
+set-window-option -g window-status-current-format ' #I #W '
+
+## set window notifications
+set-option -g visual-activity on
+set-option -g visual-content on
+set-window-option -g monitor-activity on
+set-window-option -g automatic-rename off
+
+## tmux window titling for X
+set-option -g set-titles on
+set-option -g set-titles-string '[#I] #W'
+set-window-option -g automatic-rename on
+set-window-option -g window-status-format ' #I #W '
+set-window-option -g window-status-attr bold
+
+## pane border and colors
+set-option -g pane-active-border-fg yellow
+set-option -g pane-border-fg white
Please sign in to comment.
Something went wrong with that request. Please try again.