【发布时间】:2021-07-23 00:22:30
【问题描述】:
我有一个这样的苹果脚本
#!/bin/zsh
tell application "iTerm"
activate
select first window
# Create new tab
tell current window
create tab with default profile
end tell
# Split pane
tell current session of current window
split vertically with default profile
split vertically with default profile
split vertically with default profile
end tell
# Exec commands
tell first session of current tab of current window
write text "aws-vault exec my-role -d 12h --no-session"
write text "start him"
end tell
tell second session of current tab of current window
write text "start her"
end tell
tell third session of current tab of current window
write text "start you"
end tell
tell fourth session of current tab of current window
write text "start me"
end tell
end tell
问题是脚本没有等待我从 aws 命令填写 mfa 信息。我也尝试过aws-command; start him,但它只是退出并且根本不执行start him。有人遇到过这种情况吗?
【问题讨论】:
标签: bash terminal iterm2 osascript