diff --git a/zprofile b/zprofile new file mode 100644 index 0000000..3d305c2 --- /dev/null +++ b/zprofile @@ -0,0 +1,5 @@ +# Start or reattach a tmux session when a ssh connection is established +if [[ -n "${SSH_CONNECTION}" ]] && [[ "${TERM}" != "tmux-256color" ]]; then + tmux attach-session -d || tmux new-session + exit +fi