fixup! Only close tmux session on top level shell exit

This commit is contained in:
2024-12-13 15:05:31 +01:00
parent 0dfee381f5
commit 88f3698e76
+1 -1
View File
@@ -237,7 +237,7 @@
# Create a new tmux session (with a random name) and attach.
if [[ -z "$TMUX" ]]; then
exec tmux -u new-session -s "#$(hexdump -n 4 -v -e '/1 "%02X"' /dev/urandom)"
else if [[ $SHLVL -eq 1 ]]
elif [[ $SHLVL -eq 1 ]]; then
session=$(tmux display-message -p "#S")
# kill current sesion if we are quiting the only pane
function __onExit {