How to edit Automator .action files

automatorscreen capture

I have an Automator Quick Action that captures a selected screen area to clipboard (I use Screenshot to capture to Preview). For my workflow I need to have both options on hotkeys.

It works well but there is an annoying dialog: Annoying Dialog

There seems to be no way to remove this in Automator, so I located the

System?Library/Automator/Take Screenshot.action

To see if I could suppress the dialog, but I can't figure out how. Anyone else attempted this?

Thanks!

Best Answer

Use a Run Shell Script action and call screencapture. Use -i for interactive capture. Provide a file path to save the picture to or use -c to copy the resulting picture to the clipboard instead.