Permalink
Fetching contributors…
Cannot retrieve contributors at this time
111 lines (84 sloc) 3.04 KB
# Nice colors
set -g default-terminal "screen-256color"
# Reload the config
bind-key r source-file ~/.tmux.conf \; display "Reloaded ~/.tmux.conf"
# Ignore ESC
set -g escape-time 0
# Copy/Paste
set-option -g default-command "reattach-to-user-namespace -l bash"
# Buffer size
set-option -g history-limit 10000
# Start windows at 1 instead of 0
set -g base-index 1
set -g pane-base-index 1
set -g renumber-windows on
# Autorename windows
set -g automatic-rename on
# Status bar content
set -g status on
set -g status-interval 5
set -g status-left '#(cacheout 15m mylist) #(cacheout 1h emoji-weather -temp=f -zipcode=08003)'
set -g status-right '#[fg=colour166]#(w -h | grep -v `whoami` | cut -f 1 -d " " | uniq | tr "\\\n" " " ) #[fg=colour7]#(dotmusic -p | xargs -I {} echo "{} 🎵") #[fg=colour245]#(pomodoro status) #{battery_icon}#{battery_remain} #[fg=default]%l:%M %Z '
set -g status-right-length 100
# Status bar styling
set -g status-bg colour235 # very dark grey
set -g status-fg colour7 # light grey
set -g status-left-bg colour235
set -g status-position top
set -g window-status-current-format "#[fg=colour166] #(basename '#{pane_current_path}')#F"
set -g window-status-format "#[fg=colour7] #(basename '#{pane_current_path}')"
# Show activity in other windows
set -g monitor-activity on
set -g window-status-activity-attr bold
# Messages
set -g display-time 3000
set -g message-bg colour166 # orange
set -g message-fg black
# Panes
set -g pane-border-fg colour8 # dark grey
set -g pane-active-border-fg colour7 # light grey
# Clock
set -g clock-mode-style 12
set -g clock-mode-colour colour166 # orange
# Mouse
set -g mouse on
# Pane Navigation
bind-key C-b select-pane -t :.+
bind-key h select-pane -L
bind-key j select-pane -D
bind-key k select-pane -U
bind-key l select-pane -R
# Kill all other panes except for the current one
bind-key o kill-pane -a -t .
# Tab Navigation
bind-key -n S-left prev
bind-key -n S-right next
bind-key -n C-S-left swap-window -t -1
bind-key -n C-S-right swap-window -t +1
# Open notes window
bind-key n if-shell 'tmux select-window -t 0' '' 'new-window -c ~/Notes -n notes -t 0 "vim +CtrlPRoot"'
# Pomodoro
bind-key p if-shell 'pomodoro start' ''
bind-key P if-shell 'pomodoro clear' ''
# Resize current pane to 80 columns
bind-key 8 resize-pane -x 80
# Small mode
bind-key s bind-key C-b select-pane -t :.+ \\; resize-pane -x 80
# Lock the screen
bind-key l run-shell '/System/Library/CoreServices/Menu\ Extras/User.menu/Contents/Resources/CGSession -suspend'
# Open splits in the same directory
bind '"' split-window -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
# Plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-battery'
set -g @batt_remain_short true
set -g @batt_charged_icon "🔌"
set -g @batt_charging_icon "⚡️"
set -g @batt_discharging_icon "🔋"
set -g @batt_full_charge_icon "🔋"
set -g @batt_high_charge_icon "🔋"
set -g @batt_medium_charge_icon "🔸🔋"
set -g @batt_low_charge_icon "🔻🔋"
set -g @plugin 'tmux-plugins/tmux-yank'
run '~/.tmux/plugins/tpm/tpm'