Safari脚本中打开的当前Chrome标签不起作用

时间:2013-01-01 02:25:20

标签: shell google-chrome tabs safari applescript

我想在Safari中打开我当前的Chrome网址。但我搞乱了脚本中的引号并收到错误:error "The file /$theURL does not exist." number 1

这是脚本:

property theURL : ""
tell application "Google Chrome"
    set theURL to (get URL of (active tab) of window 1)
end tell

do shell script "open -a Safari '$theURL' "

有人能指出我必须写做shell部分吗?

1 个答案:

答案 0 :(得分:0)

尝试:

do shell script "open -a Safari " & quoted form of theURL