Open up 3 terminals, run different commands from all for each of them, to set up a development environment
Solution 1:
First, you can set up multiple terminal windows, each of which can start up with a command. Just go to Terminal --> Preferences --> Settings, and create a window for each of the commands you want to kick off. Next, Terminal has the concept of "Window Groups". Open those terminal windows you want to kick off, and then save them as a window group using Window --> Save Windows as Group. Finally, you can start up Terminal using a window group. Go back to Terminal --> Preferences, and go to Start this time. Under "On open, start", select "Window Group" and then the window group you created. This will make it so on start up, terminal will kick off that group. If you just want to be able to kick off the group, but not do it on start up, just skip the last part, naturally.
Solution 2:
To open another Terminal window in Mac OSX, simply hit cmd + T
from the command line.
Solution 3:
I suppose this might help you
function tab() {
while read hostname
do
{
osascript 2>/dev/null <<EOF
tell application "System Events"
tell process "Terminal" to keystroke "t" using command down
end
tell application "Terminal"
activate
#do script with command "cd \"$PWD\"; $*" in window 1
do script with command "ssh root@$hostname" in window 1
end tell
EOF
}
done < "$1"
}
I added this function in my .bash_profile and then source the .bash_profile and invoke it using tab hostnames.txt
where hostnames.txt is text file containing a list of IP Addresses that I want to ssh to, assuming that ssh key pair is already setup.
Reference: https://stackoverflow.com/questions/7171725/open-new-terminal-tab-from-command-line-mac-os-x/8188174#8188174