fix(tmux): check is server running before connecting
This commit is contained in:
parent
5d58745a09
commit
83d1ec948a
@ -7,7 +7,7 @@ if \
|
||||
[[ ! "$TERM" =~ tmux ]] && \
|
||||
command -v tmux &>/dev/null
|
||||
then
|
||||
if tmux -N -L "$USER" server-info &>/dev/null; then
|
||||
if tmux -N -L "$USER" list-sessions &>/dev/null; then
|
||||
if [ -n "$SSH_CLIENT" ]; then
|
||||
exec tmux -N -L "$USER" new-session
|
||||
else
|
||||
|
||||
@ -7,7 +7,7 @@ if \
|
||||
[[ ! "$TERM" =~ tmux ]] && \
|
||||
command -v tmux &>/dev/null
|
||||
then
|
||||
if tmux -N -L "$USER" server-info &>/dev/null; then
|
||||
if tmux -N -L "$USER" list-sessions &>/dev/null; then
|
||||
if [ -n "$SSH_CLIENT" ]; then
|
||||
exec tmux -N -L "$USER" new-session
|
||||
else
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user