Mac Automator, what is it and what can you use it for? Automator, the name reveals it already, is intended to automate tasks within Mac OS. There are several tasks you can automate with Mac Automator. For example, you can automatically clean up the downloads in a folder, automatically change image dimensions to a certain size, or move specific files in a folder automatically to another folder. Mac Automator is very useful and can save you a lot of time when you create the workflows that are useful to you. Mac Automator has a predefined set of actions which you can use create an action. Just easily drag the actions in the workflow panel and set their values to start creating a workflow.
How to use Mac Automator?
The first time you launch Automator on a Mac, Automator wants you to save the document, by default the location is iCloud. Of course, with Automator iCloud, you can access the automated script on any Mac the Apple iCloud is synchronized with. Workflows are user only, only the user that has created them can run them.
In the next Automator window, you can pick what type of document you would like to create. I’ll explain each type of document before we continue.
Mac Automator workflow is a type of document which allows you to create a workflow, a specific set of actions within Mac Automator. Everytime you want to start a workflow you should launch Automator and execute the workflow from within Automator. Later on, in this article, I’ll provide you with an example of a workflow you can create in Automator, it’s very easy.
A Mac Automator application is a stand-alone Mac application which is built from the workflow you created in Automator. The workflow is executed from the application and not from the Automator workflow. In order to execute the workflow, you should drop a file or application on the application to trigger the workflow. You can save the application in any location on your Mac. Here you can find an example of an Automator application.
Automator service allows you execute a workflow action from the contextual menu in Finder or an App. Right-click a file, folder or specific piece of text and expand Services from the contextual menu, search for the workflow name and launch the Service Automator workflow script. Here is an example of a service workflow in Mac Automator.
Print plugin is a workflow which can be executed through the print dialog in document editors. Useful if you would like to move the PDF to a specific location, encrypt the PDF with a password or whatever. Here you can find an example of the Print Plugin Automator workflow.
Folder action is a type of workflow that is executed when a file or folder is added to the specific folder you attached the workflow to. Let’s say you have a downloads folder, and you attach a workflow to the downloads folder “add to archive”. Each new file or folder that is added to the downloads folder is automatically archived. Here you can find an example of a Folder action.
Calendar alarm allows you to trigger a workflow on a specific day and time. You can create a calendar alarm that triggers the workflow each moment you need it. In this calendar alarm example, you can see how to create a calendar alarm in Automator.
Dictation command can trigger a workflow. You should first enable Dictation before you can have access to dictation command’s in Mac OS and Automator. The best part about dictation commands is you can say everything you which, dictation commands allow custom phrases. Here you can find an example of a dictation command.
Mac Automator consists of three main panels. The actions panel (1), which consists of the Library panel with the different categories and the actions. The actions panel (2)containing the different actions available per category to automatically build workflows, and the workflow panel (3). The workflow panel is the most important, as it allows you to build workflows by simply dragging the actions to the workflow field. In the top right you can see the Record, Step and Run button to test and execute the workflow. Note that some workflows are not able to execute from Automator but require you to save the workflow and execute it on your Mac.
Let’s go back to the different workflows we can build with Automator. Earlier, I indicated that I would give an example per workflow type of how to build and run the workflow on your Mac. I have used very simple examples, you can build much more extensive workflows using Automator that suit your specific needs.
In this example, I’ll show a simple example of moving all jpeg images to an image folder. From the library folder search for the “Find Finder Items” action and set it to Search in Downloads. Leave all of the following are true, and select File extension contains, “jpg”. Search for the Move Finder Items action and set it to Images (or another folder). Execute the workflow. Use your imagination what you can build with actions and the workflow in Automator.
Services are workflows you can trigger from the contextual menu in Mac OS. In this example, I’ll show you how to create a service that moves a file to a Images folder. In the library search for “Move Finder Items”. Set the “Service receives selected” to files or folders “in any application”. Save the service, give it a name. Right-click a file or folder and from the menu select Services > “your saved name” (in this example, move to images folder). That’s it. Use your imagination and create a service with actions you prefer.
Print plugin example
Print Automator workflows are triggered when the Print action is called from a text editor. Let’s pretend you want to encrypt pdf documents. Search for the action, “Encrypt PDF documents”, add it to the workflow, in options enable the “Show this action when the workflow runs”. Search for the “Move Finder Items” and set it to Desktop. Now Save the Print plugin example, give it a name.
Open a document on your Mac, text file, doc file etc. Go to File > Print and drop down PDF, select the action you have saved. In my example, I saved it as Encrypt PDF. Execute it.
Now you see, the PDF export is asking to set up a password for it. The file will be saved on the Desktop.
Folder action example
Folder actions are triggered when something is changing in the folder you set up in the Automator workflow. In this example, I will show you how to archive a file automatically when it is added to a specific folder. First, make sure to set the folder, select the folder.
Find “Filter Finder Items” and set it to All, File extension is not zip. Search for “Create Archive” and set Where to Same Folder as input. Now all files that are moved or created in Images are automatically archived in zip format. In order to make sure the archive is not double zipped, the first filter is applied.
Calendar alarm example
What is better than every morning you wake up with Michael Jackson? Well sounds good to me. In this example I will create a calendar alarm that executes iTunes, searches for Michael Jackson and plays his music. In the actions search for “Filter iTunes Tracks”, set to tracks, all of the following is true and Artist is “your artist”. Search for the action “Start iTunes Playing”. Save the Calendar alarm.
a new event is created in Calendar on Mac. Give the event a name. Right-click the event and select show info. Change the start date, end date and repeat to every day (modify as you wish of course).
Dictation command example
In order to use dictation commands, you should enable it first. Open the Mac menu in the top left corner, (). Go to the System Preferences and open the Keyboard. In the keyboard settings open the tab Dictation and switch the checkbox to ON also enable Use enhanced dictation (1,2GB hard drive space) if you wish, it allows you to use dictation offline.
The default shortcut to activate the microphone to listen to dictation commands is the Function key, press it twice. If you have done it right a microphone logo appears. You are now able to dictate commands to your Mac.
Go back to the system preferences on your Mac and open Accessibility.
In the left menu panel select Dictation, open the Dictation Command settings.
Switch the enable advanced control checkbox to ON. Press the [+] button to add a new phrase. Give it a new, in this example i named it “Take screenshot”. So every time I press the function button twice and say “Take screenshot” Automator will take a screenshot.
Now in Automator, enter the Dictation command you have created. Enable the command enabled checkbox, in actions search for Take Screenshot and change Save to in to “new” create a new folder and save.
This it is, easy. Press the FN (function button) twice and say take screenshot. Your Mac will take a screenshot and save it to the folder you specified. Once again, use your imagination and create dictations that are useful to you.
I hope this article has helped you start Automator. It could get complicated if you are trying to create large workflows. Let me know in the comments, or leave a reply.