Combine 'notes' tmux session into 'hub'

This commit is contained in:
2026-03-12 15:27:44 -05:00
parent b9960cda51
commit fddf0392dd
3 changed files with 9 additions and 3 deletions

View File

@@ -1,4 +1,12 @@
tmux rename-window inbox
tmux rename-window notes-cmd
tmux send-keys -t :notes-cmd "cd "$DIR_NOTES"; clear; [[ -d .git ]] && git status" c-M
tmux new-window -d -n notes-$EDITOR
tmux send-keys -t :notes-$EDITOR "cd "$DIR_NOTES"; $EDITOR inbox" c-M
tmux new-window -d -n inbox
tmux send-keys -t :inbox 'cd "$DIR_INBOX"; clear; ls' c-M
tmux switch-client -t "hub:2"
clear

View File

@@ -46,7 +46,6 @@ bind-key C-f run-shell "tmux neww $DIR_SCRIPTS/tmux-session-init"
bind-key C-s choose-session
bind-key S choose-window
bind-key C-h run-shell "tmux neww $DIR_SCRIPTS/tmux-session-init hub"
bind-key C-j run-shell "tmux neww $DIR_SCRIPTS/tmux-session-init notes" \; switch-client -t "notes:2"
bind-key -r C-l switch-client -l
bind-key -r C-o last-window
bind-key -r C-n next-window

View File

@@ -25,7 +25,6 @@ tmux_target_path=''
if [[ $tmux_target_path = "." ]]; then tmux_target_name=$(basename $(pwd)) && tmux_target_path=$(pwd);
elif [[ $tmux_target_path = "hub" ]]; then tmux_target_name="hub" && tmux_target_path="$HOME";
elif [[ $tmux_target_path = "notes" ]]; then tmux_target_name="notes" && tmux_target_path="$DIR_NOTES";
elif [[ -n $tmux_target_path ]]; then tmux_target_name=$(basename "$tmux_target_path" | tr . _);
fi