Updated bashrc with default tmate.

This commit is contained in:
2021-03-06 06:58:12 +13:00
parent 5931494775
commit 578c8b7969

10
.bashrc
View File

@ -99,3 +99,13 @@ elif [ -f ~/.bw_session ]; then export BW_SESSION=$(cat ~/.bw_session);
# Otherwise unlock to start new session
else bwu; fi
# Try connect to my default tmate socket
if ! tmate -S /tmp/$USER.tmate.tmate attach; then
tmate -S /tmp/$USER.tmate.tmate new-session -s $USER -n $USER -d
tmate -S /tmp/$USER.tmate.tmate set-window-option -t $USER automatic-rename off
tmate -S /tmp/$USER.tmate.tmate set-window-option -t $USER allow-rename off
tmate -S /tmp/$USER.tmate.tmate attach
fi