一、自动操作-----在当前路径创建文本
1.打开automator.app创建应用程序
1.搜索AppleScript,添加进去
2.复制黏贴下方代码
on run {input, parameters}
tell application "Finder"
set newFile to make new file at (the target of the front window) as alias
open newFile
end tell
end run
保存automator,命名随便,为了方便易懂我在此命名为New Tetx File.app。
二、自动操作-----在当前路径创建terminal终端
1.如上面前两步骤相同创建新的自动操作
2.复制黏贴下方代码
on run {input, parameters}
tell application "Finder"
set myWin to window 1
set thePath to (quoted form of POSIX path of (target of myWin as alias))
if application "Terminal" is running then
tell application "Terminal"
do script "cd " & thePath
activate
end tell
else
tell application "Terminal"
do script "cd " & thePath in window 1
activate
end tell
end if
end tell
end run
保存automator,命名随便,为了方便易懂我在此命名为Open terminal.app。
三、把创建好的自动操作程序添加到访达的菜单栏中
1.按住command拖动至访达菜单栏
注:创建的自动操作程序是可以自定义图标的
2.创建的自动操作可以自定义图标,可以选择自己喜欢的图标或者系统已安装app的图标。
3.例如选择terminal终端图标,按command+i快速显示简介,点击图标 command+c可以复制该图标
3.然后选择刚刚创建自动操作程序,command+i快捷键显示简介,选择左上角图标,command+v即可替换图标。