Save this like mysqcript.app:
And run it as:
tell application "iTerm2"
tell current window
create tab with default profile command "ssh myuser@111.111.111.111 -i my.pem"
select last tab
tell the current session
write text "#web 1;"
end tell
create tab with default profile command "ssh myuser@111.111.111.112 -i my.pem"
select last tab
tell the current session
write text "#web 2;"
end tell
create tab with default profile command "ssh myuser@111.111.111.113 -i my.pem"
select last tab
tell the current session
write text "#worker 1;"
end tell
end tell
end tell
And run it as:
osascript mysqcript.app
No comments:
Post a Comment