You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
9 lines
242 B
Bash
9 lines
242 B
Bash
2 years ago
|
# Launch tmux if logging in over ssh
|
||
|
if [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then
|
||
|
if tmux has-session -t ssh_tmux &2>/dev/null; then
|
||
|
exec tmux -2 attach-session -t ssh_tmux
|
||
|
else
|
||
|
exec tmux -2 new-session -s ssh_tmux
|
||
|
fi
|
||
|
fi
|