You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Example: always create a shpool session when using SSH
## directly checks if it should start a tmux session to avoir running the entire zshrc twiceif [[ "$ZSH_ARGZERO"==*"zsh" ]] # don't create a shpool is an argument was given to zshthen# create a new shpool session$(printenv | grep -q '^SHPOOL_SESSION_NAME=')|| { # if we're not already in a shpool session
{
sessions=$(shpool list | tail -n +2 | cut -f1)forletterin {a..z} # sessions are named a through z to be easy to type on termux, as shpool has no autocompletedo$(echo "$sessions"| grep -q "$letter")|| {
# notify-send "Creating shpool session $letter"
shpool attach "$letter"|| notify-send "Error creating shpool session"break# we could logout here too
}
done
} || { notify-send -u critical "Error creating shpool session";echo"Error creating shpool session" }
}
$(printenv | grep -q '^SHPOOL_SESSION_NAME=')&& {
echo"Using shpool session $SHPOOL_SESSION_NAME"
}
fi