From b82ff2ba721995eb164e65333130ecc59557ed06 Mon Sep 17 00:00:00 2001 From: Charles D Date: Wed, 10 May 2023 07:27:48 -0400 Subject: [PATCH] add tmux.conf --- .config/tmux/tmux.conf | 58 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 .config/tmux/tmux.conf diff --git a/.config/tmux/tmux.conf b/.config/tmux/tmux.conf new file mode 100644 index 0000000..af58396 --- /dev/null +++ b/.config/tmux/tmux.conf @@ -0,0 +1,58 @@ +# ~/.config/tmux/tmux.conf + +set -g escape-time 0 +set -g default-terminal "screen-256color" +set -g history-limit 50000 +set -g base-index 1 +setw -g pane-base-index 1 + +# Set term title to current session window +set -g set-titles on +set -g set-titles-string "#I: #W" + +set -g prefix C-a +unbind C-b +bind-key C-a send-prefix + +unbind % +bind | split-window -h + +unbind '"' +bind - split-window -v + +unbind r +bind r source-file ~/.config/tmux/tmux.conf; display-message "Config reloaded." + +bind -r j resize-pane -D 5 +bind -r k resize-pane -U 5 +bind -r l resize-pane -R 5 +bind -r h resize-pane -L 5 + +bind -r m resize-pane -Z + +# create new windows in the same cwd +bind c new-window -c "#{pane_current_path}" + +# Prompt to rename new windows on creation +set-hook -g after-new-window 'command-prompt -I "#{window_pane}" "rename-window '%%'"' + +#set -g mouse on + +set-window-option -g mode-keys vi + +bind-key -T copy-mode-vi 'v' send -X begin-selection +bind-key -T copy-mode-vi 'y' send -X copy-selection + +unbind -T copy-mode-vi MouseDragEnd1Pane + +set -g @plugin 'tmux-plugins/tpm' + +set -g @plugin 'christoomey/vim-tmux-navigator' +set -g @plugin 'jimeh/tmux-themepack' +set -g @plugin 'tmux-plugins/tmux-resurrect' # persist tmux sessions across reboot +set -g @plugin 'tmux-plugins/tmux-continuum' # automatically saves session every 15 mins +set -g @plugin 'thewtex/tmux-mem-cpu-load' + +set -g @themepack 'powerline/default/cyan' + +run '~/.config/tmux/plugins/tpm/tpm'