我想创建一个 Automator 工作流程,它将自动将我使用 cmd+shift+3/4 拍摄的屏幕截图移动到指定文件夹,同时还将我拍摄的屏幕截图复制到剪贴板。我已经有了自动程序来移动文件,但我添加的“复制到剪贴板”操作仅将文件名复制到剪贴板,而不是图像本身。不过,由于我的“复制到剪贴板”操作,Automator 确实显示了所选的屏幕截图。有什么想法如何使用自动化工具将我拍摄的屏幕截图放入剪贴板吗?
我找到了解决方案在这里
我将其设置为在我的桌面文件夹上运行的文件夹操作。
on run {input, parameters}
set thisFile to item 1 of input
set the clipboard to (read thisFile as TIFF picture)
return thisFile
end run
Automator
quick action
'Run Applescript'
paste
我的snippet
并根据您的喜好进行修改save
/导出并双击/安装到服务system settings > keyboard > keyboard shortcuts > screenshots > uncheck command shift 4
services tab > general
并通过双击右侧区域设置按键绑定并设置为shift命令shift 4command + shift + 4
键绑定,但您可能希望另一个on run {input, parameters}
set screenshotFolder to "/Users/riley/Pictures/Screenshots/"
set currentDate to do shell script "date +'%Y%m%d%H%M%S'"
set screenshotFile to screenshotFolder & "screenshot_" & currentDate & ".png"
do shell script "/usr/sbin/screencapture -s -t png " & quoted form of screenshotFile
return input
end run
我的第一篇关于溢出的帖子!!!