osascript <<ENDtell application "Terminal" make new window activate set contents of window to "./hello" & returnend tellEND
execution error: Terminal got an error: AppleEvent handler Failed.
(-10000)
谁能告诉我怎么做?在一个完美的世界中,我也喜欢这个脚本在linux上运行,所以如果有一个可移植的方法,那就更好了.
谢谢!
解决方法 这样的事情:osascript<<EOFtell application "System Events" tell process "Terminal" to keystroke "t" using command downendtell application "Terminal" activate do script with command "./hello" in window 1end tellEOF总结
以上是内存溢出为你收集整理的linux – OSX shell脚本打开新的终端窗口并运行程序全部内容,希望文章能够帮你解决linux – OSX shell脚本打开新的终端窗口并运行程序所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)