feat: cleans up tmux config and updates to tmux-sessionator

This commit is contained in:
2024-11-19 09:16:32 -05:00
parent 917ac3ff2a
commit 9bb33cfaee
2 changed files with 7 additions and 29 deletions

View File

@@ -78,7 +78,8 @@ fi
# Create a session if it doesn't exist.
if ! tmux has-session -t "$selected_name" 2> /dev/null; then
tmux new-session -ds "$selected_name" -c "$selected"
tmux new-session -ds "$selected_name" -c "$selected" -n "editor" "${EDITOR} ."
tmux new-window -d -n "terminal" -c "$selected"
fi
[ -z $TMUX ] && tmux attach -t "$selected_name" \

View File

@@ -73,8 +73,8 @@ bind -n M-h previous-window
bind -n M-L next-window
bind C-l send-keys 'C-l'
bind f run-shell "tmux display-popup -E -w 80% -h 80% ~/.local/scripts/tmux-sessionator"
bind-key -r C run-shell -b "~/.local/scripts/tmux-sessionator ~/.dotfiles"
bind f run-shell "tmux display-popup -E -w 80% -h 80% ${SCRIPTS}/tmux-sessionator"
bind-key -r C run-shell -b "${SCRIPTS}/tmux-sessionator ~/.dotfiles"
bind S run-shell -b "~/.config/tmux/plugins/tmux-fzf/scripts/session.sh switch"
# reload new changes
@@ -91,26 +91,6 @@ set -g @plugin 'catppuccin/tmux'
set -g @plugin 'tmux-plugins/tmux-online-status'
set -g @plugin 'tmux-plugins/tmux-battery'
# set -g @catppuccin_flavor 'mocha' # latte, frappe, macchiato, mocha
# set -g @catppuccin_window_left_separator ""
# set -g @catppuccin_window_right_separator " "
# set -g @catppuccin_window_middle_separator " █"
# set -g @catppuccin_window_number_position "right"
# set -g @catppuccin_window_default_fill "number"
# set -g @catppuccin_window_current_fill "number"
# set -g @catppuccin_status_modules_right "directory session"
# set -g @catppuccin_status_left_separator " "
# set -g @catppuccin_status_right_separator ""
# set -g @catppuccin_status_right_separator_inverse "no"
# set -g @catppuccin_status_fill "icon"
# set -g @catppuccin_status_connect_separator "no"
# set -g @catppuccin_window_default_text " #{window_nam}"
# set -g @catppuccin_window_current_text "#{window_name}"
# set -g @catppuccin_window_status "icon"
# set -g @catppuccin_window_default_fill "number"
# set -g @catppuccin_window_number_position "left"
#
# set -g @catppuccin_directory_text "#{pane_current_path}"
# Configure Catppuccin
set -g @catppuccin_flavor "macchiato"
set -g @catppuccin_status_background "none"
@@ -145,10 +125,6 @@ set -ga status-right "#[bg=#{@thm_bg},fg=#{@thm_blue}] 󰭦 %Y-%m-%d 󰅐 %H:%M
# bootstrap tpm
if "test ! -d ~/.tmux/plugins/tpm" \
"run 'git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm && ~/.tmux/plugins/tpm/bin/install_plugins'"
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'
# Configure Tmux
set -g status-position top
set -g status-style "bg=#{@thm_bg}"
@@ -175,5 +151,6 @@ set -gF window-status-separator "#[bg=#{@thm_bg},fg=#{@thm_overlay_0}]│"
set -g window-status-current-format " #I#{?#{!=:#{window_name},Window},: #W,} "
set -g window-status-current-style "bg=#{@thm_peach},fg=#{@thm_bg},bold"
# Needs to stay at the bottom.
run '~/.config/tmux/plugins/tpm/tpm'
# Initialize TMUX plugin manager (keep this line at the very bottom of tmux.conf)
run '~/.tmux/plugins/tpm/tpm'