#!/bin/bash ## check interactive shell https://unix.stackexchange.com/questions/26676/how-to-check-if-a-shell-is-login-interactive-batch if [[ $- == *i* ]] ; then tmux new-session -s ansible-devspace -d tmux attach -t ansible-devspace fi