https://stackoverflow.com/questions/5447278/bash-scripts-wit...
This looks like the best solution to your question https://github.com/tmuxinator/tmuxinator