Two useful Automator workflows

24.05.2012
Automator--OS X's automation utility--gets overlooked far more than it should. It's not terribly difficult to use and it can ease the burden of performing repetitive tasks. In this week's video I cobble together a couple of simple Automator workflows--one for easily compressing files and folder and adding them to email messages and another for creating an automatic backup routine between two volumes.

• Format: MPEG-4/H.264

• Resolution: 480 x 272 (iPhone & iPod compatible)

• Size: 5.7 MB

• Length: 4 minutes, 48 seconds

I offer a new Automator workflow each and every month. You can check out all our Automator work on our . And if you're looking for additional information outside of this Macworld, check out the .

To subscribe to the Macworld Video stream via iTunes, .

You can also see a complete archive of all our videos on . Subscribe to that channels and you will be notified whenever we post a new video.

Or just point your favorite podcast-savvy RSS reader to: .

In this movie I'm going to show you how to create a couple of useful Automator workflows. We'll start with one that, with a simple drag and drop, allows you to compress and email a file. It goes like this.

Launch Automator and from the template sheet that appears, choose Application and click Choose. Here's your workflow window with libraries of actions on the left, the actions associated with the selected library next to it, and the workflow area taking up the bulk of the window.

Select the Files & Folders library and in the Actions area, drag the Create Archive action to the workflow area. We'll leave the settings as they are, which is to use the same name as the original file and save the compressed archive to the desktop.

Now select the Mail library and drag its New Mail Message action to the workflow. If you'd like, you can pre-address messages in this action--something you might do if you routinely send compressed files to the same person.

Finally, from that same Mail library add the Add Attachments to Front Message action to the workflow. Now save your workflow to the desktop and give it an intuitive name.

To invoke it, simply drop a file or folder that you'd like to compress onto the app and watch what happens.

Here's another workflow that uses an iCal event to trigger a workflow. The idea here is that we're going to create a couple of folders and have Automator back up the contents of one to the other at the same time every day.

We'll start by creating a couple of folders. I'll create one on my desktop called To Backup. I'll open this key drive that I've jacked into my Mac and create another folder called My Backup. We'll put these folders to good use in a bit.

Now launch Automator and from the template sheet choose iCal Alarm and click Choose.

Choose the Files & Folders library and then drag these actions to the workflow area: Get Specified Finder Items, Get Folder Contents, and Copy Finder Items. At this point, save your workflow.

When you do, iCal will launch and create a new event. You can then edit this event so that it repeats every day at, say 8 PM.

Now return to your workflow and drag the To Backup Folder into the first action and then drag the My Backup folder to the pop-up menu in the last action. Save it again.

Now, let's give it a try. I'll take this document on the desktop and drag it into the To Backup folder. I'll then show you the contents of the My Backup folder. Within Automator I then click on the Run button and watch what happens--the file in the To Backup folder has been copied to the My Backup folder.

The beauty of an iCal Alarm trigger is that I needn't push this Run button manually. Instead, iCal will simply trigger the workflow at the time I set within the event.