From 0cdc95f20bd588237e3f6ab12ec87381d9f38ee3 Mon Sep 17 00:00:00 2001 From: Danielle McLean Date: Wed, 22 Nov 2023 15:54:28 +1100 Subject: [PATCH] Install and enjoy the Tmux Plugin Manager :) --- dot-config/tmux/tmux.conf | 41 +++++++++++++-------------------------- 1 file changed, 13 insertions(+), 28 deletions(-) diff --git a/dot-config/tmux/tmux.conf b/dot-config/tmux/tmux.conf index 02cc89f..73de48a 100644 --- a/dot-config/tmux/tmux.conf +++ b/dot-config/tmux/tmux.conf @@ -1,39 +1,24 @@ -set -s escape-time 0 +set -g @plugin 'tmux-plugins/tpm' +set -g @plugin 'tmux-plugins/tmux-sensible' +set -g @plugin 'tmux-plugins/tmux-pain-control' -set -g focus-events on set -g set-titles on -setw -g aggressive-resize on setw -g automatic-rename on - -set -g default-command "$SHELL" -set -g default-terminal "screen-256color" +set -sa terminal-overrides ",xterm-kitty:Tc" set -g mouse on setw -g mode-keys vi -set -g status-keys vi -unbind C-b + set -g prefix C-a -bind R source-file $XDG_CONFIG_HOME/tmux/tmux.conf -bind C-a last-window bind a send-prefix +bind C-a last-window -# This stuff was yanked from http://www.hamvocke.com/blog/a-guide-to-customizing-your-tmux-conf/#changing-the-look-of-tmux -set -g status-interval 2 -set -g status-left '' -set -g status-left-length 20 -set -g status-right '#[fg=colour233,bg=colour241,bold] %d/%m #[fg=colour233,bg=colour245,bold] %H:%M:%S ' -set -g status-right-length 50 +bind -r C-n next-window +bind -r C-p previous-window -set -g status-justify left -set -g status-bg default -set -g status-fg colour12 - -setw -g window-status-format ' #I#[fg=colour237]:#[fg=colour250]#W#[fg=colour244]#F ' -setw -g window-status-bg default -setw -g window-status-fg colour138 - -setw -g window-status-current-format ' #I#[fg=colour250]:#[fg=colour255]#W#[fg=colour50]#F ' -setw -g window-status-current-attr bold -setw -g window-status-current-bg colour238 -setw -g window-status-current-fg colour81 +set-environment -g TMUX_PLUGIN_MANAGER_PATH "$XDG_CACHE_HOME/tmux/plugins" +if-shell 'test ! -d "$TMUX_PLUGIN_MANAGER_PATH"/tpm' { + run-shell 'git clone https://github.com/tmux-plugins/tpm "$TMUX_PLUGIN_MANAGER_PATH"/tpm && "$TMUX_PLUGIN_MANAGER_PATH"/tpm/bin/install_plugins' +} +run-shell '$TMUX_PLUGIN_MANAGER_PATH/tpm/tpm'