Auto create second window in tmux's session.sh

This commit is contained in:
2025-04-04 11:11:52 +02:00
parent ed137ac0bd
commit 24dab5d47d
2 changed files with 3 additions and 0 deletions
+2
View File
@@ -14,6 +14,8 @@
# Making legacy nix commands consistent as well, awesome!
nixPath = lib.mapAttrsToList (key: value: "${key}=${value.to.path}") config.nix.registry;
channel.enable = false;
optimise.automatic = true;
settings = {
warn-dirty = false;
+1
View File
@@ -22,6 +22,7 @@ current_session=$(tmux display-message -p "#S")
if ! tmux has-session "-t=$selected_name" 2> /dev/null; then
tmux new-session -ds "$selected_name" -c "$selected" -e "CMD=$EDITOR ."
tmux new-window -dt "$selected_name:1" -c "$selected" -e "CMD="
fi
tmux switch-client -t "$selected_name"