I want to write a bash script that will:
- start a new tmux session and run a script
- attach to it
- not exit after the script finishes execution
I tried this:
tmux new -d -s my_session '$SHELL -c " sleep 1; echo please dont exit after echo; sleep 1;"' tmux attach -t my_session
But this exits after the script finishes execution. How can I keep the session alive so I can attach and execute more scripts?