第一步、新建文件保存成 .scpt 文件
set cmd to ""tell application "Finder"set theWindow to window 1set thePath to (POSIX path of (target of theWindow as alias))set cmd to "cd " & "\"" & thePath & "\""end telltell application "Terminal"activatetell application "System Events" to keystroke "t" using command downdelay 0.5do script cmd in window 1end tell