diff --git a/install.sh b/install.sh index eb42963..3d29697 100755 --- a/install.sh +++ b/install.sh @@ -6,6 +6,7 @@ fi rm ~/.zshrc ln -s ~/.dotfiles/zshrc ~/.zshrc +ln -s ~/.dotfiles/tmux/tmux.conf ~/.tmux.conf touch ~/.dotfiles/zsh/device-specific sudo chsh -s $(which zsh) $USER diff --git a/tmux/tmux.conf b/tmux/tmux.conf new file mode 100644 index 0000000..aa75c7d --- /dev/null +++ b/tmux/tmux.conf @@ -0,0 +1,47 @@ +# Reload config +bind-key C-r source-file ~/.tmux.conf \; display "Config reloaded!" + +# Split Panes (additional shortcuts) +bind-key | split-window -h -c "#{pane_current_path}" # let's open pane with current directory with -c option +bind-key _ split-window -v -c "#{pane_current_path}" + +# Move to other panes with Alt+[ArrowKey] +bind -n M-Left select-pane -L +bind -n M-Right select-pane -R +bind -n M-Up select-pane -U +bind -n M-Down select-pane -D + +# Mouse support +set -g mouse on +bind -n WheelUpPane select-pane -t= \; copy-mode -e \; send-keys -M +bind -n WheelDownPane select-pane -t= \; send-keys -M + +set -g mouse-select-window on +set -g mouse-select-pane on +set -g mouse-resize-pane on + + +# Bigger history +set -g history-limit 10000 + +# Start windows/panes at 1 instead of 0 +set-option -g base-index 1 # window index will start with 1 +set-window-option -g pane-base-index 1 # pane index will start with 1 +set-option -g renumber-windows on + +# Colors +# Pane divider +set-window-option -g pane-border-style fg=colour11,bg=colour234 +set-window-option -g pane-active-border-style fg=colour118,bg=colour234 + +# Cool trick: Let's dim out any pane that's not active. +set-window-option -g window-style fg=white,bg=colour236 +set-window-option -g window-active-style fg=white,bg=colour235 + +# Command / Message line +set-window-option -g message-style fg=#111111,bold,bg=#eeeeee + +# Status Bar +set-option -g status-style fg=white,bg=#8317dd +set-window-option -g window-status-separator | + diff --git a/zsh/alias b/zsh/alias index 0d0e98f..3556604 100644 --- a/zsh/alias +++ b/zsh/alias @@ -30,6 +30,9 @@ if [[ $platform == 'Linux' ]]; then alias aptupdate='sudo apt update; sudo apt upgrade; sudo apt autoremove; sudo apt autoclean' fi +# tmux +alias tm='tmux attach -t default || tmux new -s default' + # For fun alias fucking='sudo' alias please='sudo'