The Awesome Automation Guide for Mac Users

Work smart, not hard. That’s the idea behind Mac Automation, a technology built into Apple’s OS X but frequently underutilized. Whether it’s sorting your email, searching your documents or building a playlist, you’d be amazed how many tasks can be done automatically instead of manually – if only you knew how to get started.

Lucky for you, MakeUseOf is offering a free Mac Automation guide covering just that. It explains everything you need to stop clicking your mouse so often and start letting your computer do the boring stuff for you. Take full advantage of the most powerful operating system on the planet and save yourself from time.

Table of Contents

§–Introduction

§1–Automating the Finder

§2–Smart Playlists for iTunes

§3–Smart Albums for iPhoto

§4–Smart Mailboxes and Smart Groups in Mail

§5?–?Automator to the Rescue

Introduction

Those of us who lived in the ancient era of manual electronic typewriters can most appreciate the nearly magical speed and efficiency of today’s computer technology. Even the fastest and most accurate typists in the pre-computer era couldn’t match the speed of simple word processing software used today. Computers and software make our lives easier, freeing us from performing repetitive tasks.

Digital technology makes it possible for us create, access, store and manage volumes of information and media — including digital photos, music files, and documents — replacing overstuffed file cabinets, photo albums, and crates of CDs, cassettes, and vinyl albums. Knowing how to use computers effectively enables us to get more done in less time, and to work more efficiently.

With each major update of Mac OS X, Apple has provided tools and features to use what I„m calling smart automation technology. These tools perform a variety of manual tasks for us. However, many new and some long-time Mac users haven’t always been keen on taking advantage of these features.

macauto 1   The Awesome Automation Guide for Mac Users

Thus, many Mac desktops are cluttered with files, folders and applications; libraries are disorganized; and often computers are not working as efficiently as they could because they are not effectively managed. Furthermore, many Mac users are simply wasting time performing tasks their computer can carry out for them.

Who This Guide Is For

Knowing how powerful and useful Mac automation tools can be, I wrote this MUO Mac Automation Guide for new and existing Mac users who haven’t taken advantage of the smart automation features of OS X Snow Leopard. This guide will break down how to automate files, folders, and tasks in four OS X applications:

  • Smart Folders in the Finder
  • Smart Playlists in iTunes
  • Smart Albums in iPhoto
  • Smart Mailboxes in Mail

In addition, in the last section I will introduce a very under-used application called Automator — a program, included in Mac OS X, designed for general Mac users to create automation actions and applications without any prior knowledge or use of computer programming or code. Automator may initially appear difficult to use, but after following the instructions in this book you will see how easy it is to create your own hacks.

This guide will be especially useful for Mac users who work several hours per day at their computers and constantly launch applications, click menu buttons, and save, locate, rename files and folders.

Are Apple’s smart automation features fairly new to you? Don’t feel in any way intimated by what you’re about to learn. I will explain these features using a clear step-by-step process, with screen shots on nearly every page. This guide presents practical examples that average Mac users can incorporate in their workflow. As you follow the step-by-step tutorials for creating Smart Folders, playlists, albums, mailboxes, and workflows you will quickly start producing automations to fit your particular needs.

As you work through the chapters of this guide, feel free to email me questions you have about instructions that are not clear to you.

You don’t have to begin with the first chapter in order start using this e-book. If you„re a big time iTunes user, you might want to start with that chapter. If you want to get your iPhoto library better organized, then start with chapter 3. You will see that setting up automations in each of the Mac applications presented in this guide is very similar to one another.

Have fun working through this guide, and keep visiting MakeUseOf.com for the best and latest in how-to computer and Internet technology.

Chapter 1: Automating the Finder

How to Create Smart Folders

The Mac Finder is probably among the most used applications on your Mac. It’s the place where you store, navigate and locate nearly all of the content (e.g., documents, images, and music files) on your hard drive.

The more items you add to your computer, the more challenging it is to locate files when you need them. This is why Apple came up with what are called Smart Folders, which basically consists of a collection of files based on a set of search criteria.

When you install Mac OS X on your Mac, it includes a set of Smart Folders already set up for you.

Default Set of Smart Folders

macauto 2   The Awesome Automation Guide for Mac Users

If you have never clicked on these Smart Folders, open a Finder window and scroll to the bottom of the Side Bar. You should then see a set of purple folders as well as ones that have a clock icon. These are Smart Folders.

Click on the folder named, “Today”. It consists of all the files you created on the current day. This folder is useful if you forget where you saved a file or if you to want to quickly access it without having to open two or more folders to locate a file. The same goes for “Yesterday” and “Past Week” Smart Folders.

Hidden Files

macauto 3   The Awesome Automation Guide for Mac Users

When you open these folders in the Finder, based on the criteria set for them, search results will probably also include hidden files you don’t ordinarily see. Do not delete or tamper with these files unless you have a specific reason for doing so. In order to keep these files from showing up, you will need to change the search criteria to exclude them. More about this later.

How to Create a Custom Smart Folder

The biggest challenge in creating Smart Folders is figuring out what criteria you need for the type of search you want to do. The more familiar you become with the search options for Smart Folders, the easier it will be to create them.

So let’s create a Smart Folder.

Select File>New Smart Folder

macauto 4   The Awesome Automation Guide for Mac Users

In a Finder window, go to File>New Smart Folder

Setting Up Smart Folder Rules

macauto 5   The Awesome Automation Guide for Mac Users

Click on the + button on the far right of the search box. Notice that the search will be based upon all the contents of your Mac. I will show you later how to conduct searches in a single folder.

macauto 6   The Awesome Automation Guide for Mac Users
  1. The first pop-up menu consists of a set of attributes for the kinds of items you want to search for. These attributes include file name, type of file, date created, etc. For this tutorial, let’s use Name, which refers to the name of files.
  2. Now click on the second pop-up menu to further refine the search by selecting “ends with”.
  3. We’re going to search for Microsoft Word files, so in the text field, type “docx”—without the quotation marks. If you have Word files on your computer they should automatically start showing up in this Smart Folder. If you don’t have Word files, you can type, “rtf,” for TextEdit files, or “pages” for Pages files.

The search criteria for this Smart Folder looks for and gathers Word documents into one folder, though the documents themselves may be saved in many different folders on your hard drive.

At this point you could save the criteria for this Smart Folder, but let’s add other criteria to refine the search.

Add Another Criteria

macauto 7   The Awesome Automation Guide for Mac Users
  1. Click the + button to add another set of criteria.
  2. Click the first pop-up menu and select “Created date”.
  3. Click the second pop-up menu and select “this week”.

Now our Smart Folder will filter for Word documents created since the beginning of the week.

There are numerous criteria we could set for this Smart Folder; it all depends on what your needs are. Feel free to customize your search any way you like.

Now let’s save the Smart Folder.

Saving a Smart Folder

macauto 8   The Awesome Automation Guide for Mac Users

You can save searches/Smart Folders any where you like, but the default folder for them is in Home>Library>Saved Searches

Be sure to give your search a title. At the bottom of the Save dialog box there is an Add to Sidebar checkbox. You will probably want to leave the box checked so that you can easily access it without having to open it with the library folder.

Edit/Delete Smart Folder

macauto 9   The Awesome Automation Guide for Mac Users

You can manually drag Smart Folders in any order you like. You can also edit, rename, or remove a Smart Folder by right- or Control- clicking on the folder and choosing what you want to do from the shortcut menu.

Other Search Criteria

You can find additional search criteria specific to various applications on your Mac by selecting “Other” in the first pop-up menu.

macauto 10   The Awesome Automation Guide for Mac Users
macauto 11   The Awesome Automation Guide for Mac Users

Scan these search attributes to see if any of them apply to the type of files and items you frequently search for on your computer.

Sample Finder Folders

The following are screenshots of sample Smart Folders. Use these ideas to generate Smart Folders for your unique needs.

Recently Used Applications

macauto 12   The Awesome Automation Guide for Mac Users

I use this Smart Folder to locate applications I have recently used.

PDFs Related to Photography

macauto 13   The Awesome Automation Guide for Mac Users

This search criteria looks for PDFs that contain the word “photography.” I have hundreds of PDFs on my hard drive and this Smart Folder is a quick way to find PDFs related to a particular topic.

Recent JPEG Files

macauto 14   The Awesome Automation Guide for Mac Users

This search rule is for recently opened JPEG files, the kind of files taken with your digital camera.

Recent Photoshop Search

macauto 15   The Awesome Automation Guide for Mac Users

This is an example of search criteria that looks for files created with Adobe Photoshop. Criteria can be set up for any application: just search for that program?s standard file extension (e.g, “.psd” for Photoshop or “.docx” for Word.)

Chapter 2: Smart Playlists for iTunes

Creating Smart Playlists in iTunes

Due to the popularity of Apple’s mobile devices (including the iPhone, iPad, and all the various models of iPods), its media player application, iTunes, is one of the most heavily used Apple applications.

iTunes is not just an MP3 player; it also plays movies, podcasts, and audio books. It can even store PDFs and e-books.

When your iTunes library starts brimming with thousands of media files, Apple’s Smart Playlist feature is the best way to manage and access them. Once you learn how to create and use Smart Playlists you will want to create several dozen of them, because they virtually do the job of searching and filtering media, and putting them in playlists for you.

Regular, non-automated playlists are useful, but Smart Playlists can be like having a personal DJ. They search through all your music files for the tracks you prefer the most, or the ones you haven?t played in the last three months. There?s hardly a limit to the type of search criteria you can set up.

Note: the screenshots for this chapter are based on iTunes 9. In the middle of writing this guide, Apple released iTunes 10. While the most recent update has many new features, the Smart Playlists features are the same.

If you are new to iTunes and need a good introduction, check out MakeUseOf’sThe Big Book of iTunes, which includes 50+ pages of great iTunes tips and tricks.

Create a New Smart Playlist

macauto 16   The Awesome Automation Guide for Mac Users

Similar to other applications using smart automation, you can create Smart Playlists by choosing in iTunes, File>New Smart Playlist.

Search Criteria for Smart Playlists

macauto 17   The Awesome Automation Guide for Mac Users

You will notice there are dozens of attributes in which to build search criteria. With iTunes Smart Playlists, you can do Boolean searches, which is something you can?t do with Finder Smart Folders. Boolean criteria means that you can include AND, OR, and NOT operators, enabling you to do complex searches.

Here’s a breakdown of items in the Smart Playlists dialog box.

  1. When the “Match the following rule” box is checked, it means all the rules you set must apply. When it’s unchecked, it means one or more of the rules in the search criteria must apply.
  2. This first set of attributes consists of information about the media files in your iTunes library including song titles, artist name, ratings, genre, and play count.
  3. The second set of attributes consists of ways you can limit your search. The Input box is also used to refine searches. Likewise, the attributes below the first set are used to further define your search criteria.

If you have never created a Smart Playlist, the above information will make sense after you complete the following examples. Let’s get ready to have some fun!

Favorite Genre Smart Playlist

macauto 18   The Awesome Automation Guide for Mac Users
  1. In the first pop-up menu, select “Genre”. In the second, select “is.” And in the third text field, type “R&B” or whatever your favorite genre is.
  2. Leave the “Live updating” box checked. This means new songs added to your iTunes library matching this criteria will automatically appear in this Smart Playlist.
  3. Click OK

Smart Playlist of All Your R&B Songs

macauto 19   The Awesome Automation Guide for Mac Users

You will see in the sidebar of your iTunes a Smart Playlist of all your R&B songs. You can click on the title of the Smart Playlist and change it if you like.

Now let’s go back and create a similar Smart Playlist in which the search criterion is more refined.

Recently Played R&B

macauto 20   The Awesome Automation Guide for Mac Users

Say you have been playing a set of recently purchased R&B songs and you want to play them again, without having to search through your iTunes library. You might even want to copy this Smart Playlist to your iPhone or iPod touch so you can play it on the go.

Create a new Smart Playlist or edit the one you just created. To edit an existing Smart Playlist, select the list in the iTunes sidebar and go to File>Edit Smart Playlist. You can also right- or Control-click on Smart Playlist and select from the pop-up menu, Edit Smart Playlist.

  1. Use the criteria in the first Smart Playlist we did above, then click the + button.
  2. In the second set of criteria, choose the following attributes: Last Played>in in the last> 2 weeks.
  3. Optional: check the Limit to “25 items box”, and choose selected by “most recently played” in the pop-up menu.
  4. Optional: Check the “Match only checked items box” if you want this Smart Playlist to play only songs that you have checked to be automatically played.
  5. Optional: Click the “Live updating”box if you want the playlist to automatically update.

Ratings and Play counts

macauto 21   The Awesome Automation Guide for Mac Users

The criteria for many of the Smart Playlists you will want to create will depend on your iTunes files having certain track and album information. In addition, the more you rate and play tracks, the more types of Smart Playlists you can create.

Track Info

macauto 22   The Awesome Automation Guide for Mac Users

When you purchase and download media files from the iTunes Store or other established sites, those files will typically track the name, artist(s), year, genre, etc. You may have to manually add this information for files that you import into your library from other sources.

For some iTunes users rating songs can be a big hassle, but I suggest that you at least rate your favorite songs. When a favorite track is playing give it a 5 star rating.

If you have been playing tracks in iTunes for several months, you could create a Smart Playlist that searches for all your frequently played tracks, which you then could give 5 stars to.

The point is that the more information your iTunes tracks contain the more types of Smart Playlists you can create.

Sample Smart Playlists

The options for creating iTunes Smart Playlists can be both simple and complex. You will want Smart Playlists which help you organize your iTunes library as well as Smart Playlists which help keep your Apple mobile device(s) up to date with new and favorite music.

Smart Playlists can also be your personal DJ: they can, for example, deliver up random tracks from your list of favorites.

The following are some sample Smart Playlists to get you thinking about the possibilities. Remember, Smart Playlists can be created for any type of media files in your iTunes library, including movie and e-book files.

Old School Songs

macauto 23   The Awesome Automation Guide for Mac Users

This Smart Playlist will contain 25 random songs produced in the 1970s or any date you desire. This search requires media tracks in your library include the appropriate release dates.

Note: Smart Playlists like this one don’t actually update or refresh automatically. You have to manually remove the songs from the playlists in order for it to refresh. Songs removed from your Smart Playlists are not removed from your iTunes Library; they are just removed from the playlist and replaced with new tracks.

Here’s a couple of ways to do this:

Refreshing a Smart Playlist: Method 1

macauto 24   The Awesome Automation Guide for Mac Users

To delete the songs from a Smart Playlist, press Command+A to select all the songs, and then press the Delete key. This process only removes the songs from the Smart Playlists, not from your iTunes library. After you delete them, a new set of songs will appear.

Refreshing a Smart Playlist: Method 2

macauto 25   The Awesome Automation Guide for Mac Users

Another way to refresh a Smart Playlist: include an attribute or rule that causes songs to drop off and be replaced. For example, in this extended Smart Playlist only songs not played in the last 30 days remain.

Refreshing a Smart Playlist: Method 3

macauto 26   The Awesome Automation Guide for Mac Users

A third method: add a play count attribute. This means only songs with a play count of less than say 5 will be included in the list. Once a song is played more than 5 times, it will be replaced.

Unplayed Favorites

macauto 27   The Awesome Automation Guide for Mac Users

This Smart Playlist includes favorite songs you haven’t played in the last 14 days.

Music Video

macauto 28   The Awesome Automation Guide for Mac Users

This Smart Playlist collects and updates all the music videos that you import into your iTunes library. You can create similar Smart Playlists for all your genres of media.

Not Played in 3 Months

macauto 29   The Awesome Automation Guide for Mac Users

Whenever I think I need to buy more music, I check out this Smart Playlist to see how many jazz songs I haven’t played in a while. This playlist makes me realize that maybe I don’t need to purchase new songs yet.

Recently Downloaded Podcasts

macauto 30   The Awesome Automation Guide for Mac Users

If you’re a heavy podcast listener, this Smart Playlist will include podcasts downloaded in the last week.

Long or Short Songs

macauto 31   The Awesome Automation Guide for Mac Users

If you’re in the mood for playing extra long or extra short songs, try this Smart Playlist.

Skipped Tracks

macauto 32   The Awesome Automation Guide for Mac Users

iTunes can keep track of songs you skipped — that is, tracks you played for at least two seconds but no longer than twenty seconds. This is a useful way to find songs you no longer find interesting. You might rate these songs down a few stars or delete them all together.

Romantic Songs

macauto 33   The Awesome Automation Guide for Mac Users

In a romantic mood? This Smart Playlist searches for titles of songs containing the word, “you,” which is often included in romantic songs. If you want to be more precise you could go through and label albums and tracks as “romantic.”

Albums Missing Artwork

macauto 34   The Awesome Automation Guide for Mac Users

This Smart Playlist will keep you updated on which albums or playlists are missing an album cover.

Check out this MUO article on getting free album cover art for iTunes.

All Music Smart Playlist

macauto 35   The Awesome Automation Guide for Mac Users

This smart playlist consists of only your music tracks. In turn, this Smart Playlist can also be used as an attribute for other Smart Playlists, as in the following:

macauto 36   The Awesome Automation Guide for Mac Users

Chapter 3: Smart Albums for iPhoto

Creating Smart Albums in iPhoto

Smart Albums are the best way to manage and access your photos in your iPhoto library. Personally, I prefer Smart Albums over iPhoto„s Faces and Places features. With Smart Albums, you can set up rules to precisely search for and present the photos you want. When you add keywords, titles, and ratings to your imported images, you can create powerful Smart Albums that help you locate photos a lot faster.

If you have created Smart Playlists and Smart Folders, then you pretty much know how to create Smart Albums in iPhoto. The process is the same.

Let?s create a sample smart album.

New Smart Album

macauto 37   The Awesome Automation Guide for Mac Users

Click on File>New Smart Album. In the drop-down palette, you will see the familiar set of conditions. We will start with a straightforward Smart Album.

macauto 38   The Awesome Automation Guide for Mac Users

You have no doubt imported hundreds if not thousands of photos into your iPhoto library, but typically you want to show off only your favorites. This Smart Album is useful just for that, especially when you are putting together a slide show, photo book, a web gallery, or anything else.

For this Smart Album, select “My Rating” in the first pop-up menu, “is” in the second, and add 5 stars. That’s it. If you have rated your photos, this Smart Album will collect all your best photos in one album.

But wait, we can further narrow the search for the type of photos we want to include.

Favorite Holiday Photos

macauto 39   The Awesome Automation Guide for Mac Users

If you apply keywords to your photos, you can create Smart Albums for each of the major keywords, such as “holiday” photos, “birthdays”, individual family members, and “vacation” shots. It only takes a few minutes to apply keywords to images once you import them, and when you do you can make better use of the Smart Album automation in iPhoto.

Camera Model

macauto 40   The Awesome Automation Guide for Mac Users

If you use more than one camera, there is a Camera Model attribute you can use to collect all photos shot by each of your cameras. This is really useful for collecting all your iPhone camera images.

macauto 41   The Awesome Automation Guide for Mac Users

To create this Smart Album, select “Camera Model” in the first pop-up menu, and “is” in the second. iPhoto will then go through your iPhoto library and identify the digital camera models for the photos you have imported into iPhoto. Select your model to create your Smart Album.

Sample iPhoto Smart Albums

Vacation Photos

macauto 42   The Awesome Automation Guide for Mac Users

Birthday Photos

macauto 43   The Awesome Automation Guide for Mac Users

Recent Favorites

macauto 44   The Awesome Automation Guide for Mac Users

The Date condition refers to the date the photos were taken, not the day they were imported into your iPhoto library. This Smart Album is useful for getting at your favorite recent photos.

Unrated Photos

macauto 45   The Awesome Automation Guide for Mac Users

As with iTunes tracks, it is a good idea to get into the habit of rating your images after you import them. Even if you don’t want to spend time rating them all at least give the best images a 5 star rating and your least favorites a 1. Or leave the poorly shot photos unrated, so you can later decide to trash them if your iPhoto library becomes bloated. A similar Smart Album can be done for “untitled“ and untagged (no keyword) photos.

RAW Photos

macauto 46   The Awesome Automation Guide for Mac Users

RAW photos are typically very large files, so it’s a good idea to keep track of them in a Smart Album.

Non-edited Photos

macauto 47   The Awesome Automation Guide for Mac Users

If you’re keen on editing your images, this is a useful Smart Album for collecting un-edited photos. You can of course add conditions for photos shot on a particular day or from a particular album.

50mm Lens Photos

macauto 48   The Awesome Automation Guide for Mac Users

If you have a special lens you like to shoot with, this Smart Album is great for collecting photos taken at a particular focal length.

Chapter 4: Smart Mailboxes and Smart Groups in Mail

How to Create Smart Mailboxes

Most of us have a love/hate relationship with our email box. We like the speed and efficiency of sending and receiving emails, but we detest the countless (often spam) messages we receive on a daily basis. Creating Smart Mailboxes and Mail rules is one solution to the problem of managing email messages.

Smart Mailboxes collect email messages based on conditions you set up for them. Smart Mailboxes are a useful way to automatically manage, filter and access your messages. You can use Smart Mailboxes to prioritize what messages you will read first and which ones you will send straight to the trash can.

Similarly, Apple’s Mail program includes the ability to set up automatic mail rules for incoming messages.

Let’s first learn how to set up a Smart Mailbox.

New Smart Mailbox

macauto 49   The Awesome Automation Guide for Mac Users

In Mail, choose Mailbox > New Smart Mailbox. Notice there is also a menu item for “New Mailbox”. The regular mailbox requires you to manually add messages to them, whereas Smart Mailboxes automatically collect messages based on the conditions set for them.

Today’s Unread Mail

macauto 50   The Awesome Automation Guide for Mac Users

Our first Smart Mailbox will be one which collects your unread mail for the current day.

  1. In the first pop-up menu, select Date Received and in the second menu, select “is today.”
  2. Click the Add (+) button to add another condition.
  3. In the pop-up menu select “Message is Unread”
  4. Select “all” so both conditions must apply
  5. If you want to include current messages that have been sent to the trash and messages in your Sent mailboxes, select the checkboxes.
macauto 51   The Awesome Automation Guide for Mac Users

Your new Smart Mailbox will appear in the sidebar under Smart Mailboxes. As you can see, all Smart Mailboxes use a purple folder icon with a gear image in the middle. Regular mailboxes use blue folder icons.

Editing Smart Mailboxes

macauto 52   The Awesome Automation Guide for Mac Users

You can right- or Control-click on a Smart Mailbox and edit its conditions, rename it, or delete it all together.

A Sender Smart Mailbox

macauto 53   The Awesome Automation Guide for Mac Users

You no doubt receive email messages from individual family members, friends, or companies that you would like to quickly access in a folder. A Smart Mailbox can collect those messages for you, and you can quickly create the Smart Mailbox with a few less steps than described in the above how-to. Here’s how:

  1. Select messages from someone or some company for which you would like to create Smart Mailbox.
  2. Right- or Control-click on the sender’s email address and select Create Smart Mailbox from the shortcut menu.
macauto 54   The Awesome Automation Guide for Mac Users

A Smart Mailbox will appear with the “From” condition set up for you. You might want to change the second pop-up menu to “Is equal to,” if you think another email address might contain the same name or part of the name for the address you base the Smart Mailbox on.

Additional Conditions

macauto 55   The Awesome Automation Guide for Mac Users

You might add another condition for messages that you sent to a specified sender. To do this, click the Add (+) button and select Any Recipient from the pop-up menu and then copy and paste the sender’s address in the box.

  1. Check the “Include messages from Sent” box
  2. Choose “any” as the match attribute so that both types of messages will be collected.

Note: If you select “all” for this Smart Mailbox, nothing will appear in the box. Rarely is the sender of a message also the recipient.

Sample Smart Mailboxes

The following are screen shots of sample Smart Mailboxes. Use these ideas to generate Smart Mailboxes for your unique needs.

Flagged Messages

macauto 56   The Awesome Automation Guide for Mac Users

Collects all flagged messages.

Messages with Attachments

macauto 57   The Awesome Automation Guide for Mac Users

Messages with attachments can eat up significant hard drive space. This Smart Mailbox is useful for keeping an eye on all your messages with attachments.

Old Mail

macauto 58   The Awesome Automation Guide for Mac Users

This Smart Mailbox can assist you in locating and deleting old email.

macauto 59   The Awesome Automation Guide for Mac Users

This Smart Mailbox consists of only emails that you have replied to.

Setting Up Mail Rules

Another way to automatically search for, filter and manage emails is to use Mail rules, which are applied to messages as they arrive into your Mailboxes. Mail can automatically, for example, highlight, forward, mark as read, flag or delete incoming messages based on the conditions you set.

Adding Rules

macauto 60   The Awesome Automation Guide for Mac Users

You create and add rules by opening Mail’s Preferences and selecting “Rules” in the menu bar. Next, click the Add Rule button. We’ll start off with a rule that automatically trashes specified unwanted messages.

Setting Conditions

macauto 61   The Awesome Automation Guide for Mac Users

One way to set up Mail rules is to first identify an email message in your Mailbox which you want to apply a Mail rule to. For example, one summer I kept receiving email messages from a family member who was sending about three or four emails a day to me and other family members on his list. The emails contained the subject line: “Re: PROBLEM SOLVING.” At first the discussion was interesting, but after a while I didn?t want to read the messages any more. However, I didn?t want to be taken off the family list.

So I set up a Mail rule to automatically move his messages to the trash.

To set up this Mail rule, I selected one of the “PROBLEM SOLVING” messages, and opened Rules in Mail’s Preferences. After clicking Add Rule, I selected Subject in the first pop-up menu. In the second pop-up menu, I selected “Is equal to,” rather than “Contains,” to make sure the rule applied to only emails with the subject line, “PROBLEM SOLVING”.

Note: when you select a message and add a rule, Mail will automatically fill the information from the content of “From,” “To,” or “Subject” of the selected message. You can also edit this information based on your needs.

Trash Immediately

macauto 62   The Awesome Automation Guide for Mac Users

After you set up a rule for one or more specified messages, you need to set rules that are to be applied to specified message(s).

As you can see, you can have designated messages moved, copied, replied to, deleted, redirected, marked, flagged, etc. I chose to have “PROBLEM SOLVING” messages moved to the Trash. This means I could check my trash and retrieve the message before it’s finally deleted.

Apply Rules

macauto 63   The Awesome Automation Guide for Mac Users

After you click the OK button, the above question will pop up. If you choose Apply, the rules will be immediately applied to all messages that fit the rules you set. If you prefer the actions to apply to only future incoming messages, choose “Don’t Apply”.

Thinking About Mail Rules

macauto 64   The Awesome Automation Guide for Mac Users

Setting up Mail rules can be a little more complicated than setting up Smart Mailboxes or Smart Playlists, but they are can be very powerful for filtering and managing incoming and existing messages. To figure out the type of rules you can set up, view the options for the conditions you can set up for specified emails.

  1. First think about and select the search criteria. These options include messages from a sender(s), recipient(s), the subject line, or the specific content of email messages. Criteria for selections can also be based on email messages from contacts in your Address Book or previous recipients of your emails. The key to setting rules is to first think about what types of messages you want to apply rules to.
  2. Next, you need to figure what actions you want applied to messages you set rules for.

The following section will suggest some other basic rules illustrating the type of rules you can set up.

Note About Deleting and Trashing Messages

macauto 65   The Awesome Automation Guide for Mac Users

When you choose to have messages automatically deleted, by default Mail doesn’t actually erase those messages until after a certain period of time. This is a safety net so that you can retrieve messages before they are deleted.

But if you want to change the conditions for when messages are deleted you can do so by opening Mail Preferences, choosing Accounts > Mailbox Behaviours. In the Trash section you can change how you want Mail to handle deleted messages.

Sample Mail Rules

Re-direct Mail

macauto 66   The Awesome Automation Guide for Mac Users

My MobileMe account is the only email account I sync to my iPhone, so I use this rule to send specific messages to my Mobileme account.

Delete Messages

macauto 67   The Awesome Automation Guide for Mac Users

Since I know I won’t need these coupon messages after a certain period of time, I set up a Mail rule to have them trashed.

Recent Purchases

macauto 68   The Awesome Automation Guide for Mac Users

This Mail rule sends all emails to a regular a Mailbox (Mailbox > New Mailbox) named “Recent Purchases”. Most email receipts meet one or more of the listed conditions, so it?s a useful way to filter those messages.

To create this type of Mail rule, base the conditions on the various receipts you have received.

Amazon Receipts

macauto 69   The Awesome Automation Guide for Mac Users

Similar to the above Mail rule, you can set up a rule for a particular company.

Delete Ad Emails

macauto 70   The Awesome Automation Guide for Mac Users

There are particular email ads I want to see but do not want saved; this Mail rule deletes them after 3 days. I create a similar rule for each individual ad or merchant.

Client Email

macauto 71   The Awesome Automation Guide for Mac Users

This Mail rule lets me know when I receive emails from my clients.

Chapter 5: Automator to the Rescue

Introduction to Automator

Smart Playlists, Mail rules, Smart Folders, and Smart Albums can only automate tasks within their respective applications. For even broader system-wide automations Apple introduced, starting with Mac OS X Tiger, a program called Automator. Unlike a similar automation program, AppleScript, Automator requires no knowledge of programming language.

Automator can perform and execute tasks that you perform manually on your Mac, but it does require you to think a little like a programmer.in that you need to assemble a workflow of automated actions.

Say, for instance, you launch four or five websites on a regular basis. While it?s not a lot of trouble to click bookmarks to download these pages, you can set up what is called an Automator workflow to open those pages for you every day or on specified days, at a specified time. So when you arrive at the computer in the morning, coffee in hand, your specified websites are already open and ready to go.

If you are fairly new to computing or to the Mac, Automator may appear complicated. The program is not, at first use, as intuitive as iTunes or iPhoto. But if you like what you can do with smart automation in other Mac applications, you will find that Automator gives you even more features for automating computer tasks.

Let’s open Automator and see what?s under its hood.

Automator‘s User Interface

macauto 72   The Awesome Automation Guide for Mac Users

While Automator looks very different from most Mac applications you use on a regular basis, its user interface is actually quite simple.

  1. It consists of what are called “Actions” that perform specific tasks, such copying an item, ejecting a disk, resizing a photo, saving a file. Sounds familiar, right? Yes, many of the actions you see in Automator’s Actions Library do no more than the steps and tasks you usually perform manually.
  2. Actions are categorized by applications, as well other parts of your Mac. iTunes and iCal each has a set of actions, as do the Finder and iPhoto. Some third-party developers also create actions for their programs.
  3. The third major part of Automator is the workflow area. You drag individual actions into this area to create a workflow that can be ran either as an application, an iCal automation, a folder action, or a Services action. You can also save workflows as a Print or Image Capture plug-in.

After you build and save an action that performs the way you want, Automator doesn’t need to be open in order for workflows to run.

Okay, enough general talk. Let’s dive in and create a simple workflow to demonstrate how Automator works.

Template Workflows

macauto 73   The Awesome Automation Guide for Mac Users

Automator is in your Application’s folder. Upon launching it, a window will drop down providing you with different templates from which you can choose from to build your workflow.

Let’s start with the general “Workflow” template. Click the Choose button and let’s get started.

Locating Actions

macauto 74   The Awesome Automation Guide for Mac Users

When you first launch Automator, you may not know where to find specific actions. Say we want to build a workflow that launches three or four applications, one after another.

Let’s discover what actions in Automator deal with applications. In the Automator search box, type the word “application”.

We see in the results there is an action called, “Launch Application”. Click on that Action and drag it into the Workflow area.

macauto 75   The Awesome Automation Guide for Mac Users

When you select an action, a description of what it does appears at the bottom of the Actions Library.

macauto 76   The Awesome Automation Guide for Mac Users

Now select and drag that same action into your workflow area three times. For each individual Action, select the pop-up menu and choose an application you want to launch with a single click.

This workflow works similar to how you might specify certain applications to automatically launch when you log onto your computer, except in this case the three or four applications can be automatically launched whenever you want.

macauto 77   The Awesome Automation Guide for Mac Users

To test out this workflow, you can click the Run button in Automator’s toolbar. Note: some workflows you put together cannot be run until you actually save it as say an iCal or Folder Action.

Saving An Action

macauto 78   The Awesome Automation Guide for Mac Users

There are a few ways you can save workflows.

  1. When you save it as a Workflow, it means you can re-open it in Automator in order to do more work on it.
  2. If you save it as an Application, it means you can launch and run it like any other application. And just think, you did it without using a bit of programming code language.

So let’s save it as an Application. I save most of my workflows and workflow Applications in a folder so I can find them all in one place.

How Automator Files Are Identified

macauto 79   The Awesome Automation Guide for Mac Users

Notice that workflows saved as applications end with “app”, indicating it functions as an application. If you save your workflow as a Workflow, the file name will end with “workflow.”

When you click on your workflow application, it will launch your specified programs.

Why and When to Create Automations

You may be asking yourself if it’s worth the time to build Automation workflows for small tasks. Well, if you spend a significant amount of time working at your computer, you no doubt perform repetitive tasks that could be done automatically for you. You may work at your computer so much that even saving yourself a few extra clicks in a process would be a nice little time saver.

So basically, you want to think about using Automator when you find yourself performing repetitive tasks that you wish could be done automatically for you.

For example, we just created a workflow for launching a set of applications. A similar workflow could be done to launch websites, text files or photos, or a set of folders. If you email someone or a group of people on a regular basis, you could create a Mail workflow that sets an email for you, including the address(es) and subject you typically use when emailing that person.

Each time you save a file to a particular folder, you can back it up to a remote folder on a server, such as Dropbox. Automator can do that for you.

You may have a document you print on a regular basis. You could create a workflow which automatically prints the document for you. Or say you have an application in which each time you launch it, all the other applications on your desktop hide so that you won’t be distracted. Again, that?s a workflow you can build. It will save you some clicking and help you get things done a little faster.

Just think about simple tasks you perform and see if there are Actions inside of Automator that you can use to perform them for you.

Let’s learn about another Automator workflow, this time using an iCal.

Creating an iCal Workflow

macauto 80   The Awesome Automation Guide for Mac Users

Start a new workflow in Automator, and this time select the iCal Alarm template. We’re going to build a workflow which automatically launches a set of your favorite websites every weekday morning.

Get Specified URLs

macauto 81   The Awesome Automation Guide for Mac Users

In order to figure out what Actions we might need, we can either do a search for Actions related to websites or URLs or we can click on the Internet category in Automator’s Action Library and see it what it has to offer.

Let’s do the latter. Scroll and select the “Get Specified URLs” and drag it into your workflow. Before you move it, go ahead and take a look at the other Actions available to you. You might discover some different ideas.

macauto 82   The Awesome Automation Guide for Mac Users
  1. Drag the “Get Specified URLs” Action into the workflow area, and then select the “Display Webpages” Action and drag it under the first one.
  2. When two Actions can work together, Automator will show a link between them. Sometimes the link will be shown, but for different reasons, the workflow still might not work as you expect. You will need to experiment with different options.
  3. Now add a set of favorite URLs to the first Action. You can remove the apple.com from the list.

Finally run a test to see if it works okay.

Post iCal Alarm

macauto 83   The Awesome Automation Guide for Mac Users

When using the iCal workflow template, Automator will automatically save the workflow as an iCal alarm. Give your workflow/alarm a name that will appear in your iCal calendar.

Set Up Alarm

macauto 84   The Awesome Automation Guide for Mac Users

Set up your iCal alarm to trigger your Automator workflow. In the example above, I have set up the workflow to run every weekday morning, at 8:30a.m. There are other applications, like QuicKeys 4.0 and Alarm Clock Pro that are better for setting up these types of calendar automations. But with Automator installed by default as part of Mac OS X, it is definitely worth using for these types of automations,saving the extra expense of a third party application.

Creating a Folder Action Using Automator

Another type of useful Automator workflow is what is called a Folder Action. Folder Actions enable a designated folder to trigger a workflow when an item is added to it.

Let?s examine how it works.

Create a New Workflow

macauto 85   The Awesome Automation Guide for Mac Users

Fire up Automator and select the Folder Action template.

Select a Folder

macauto 86   The Awesome Automation Guide for Mac Users

At the top of the workflow window, click on the pop-up menu and create or select a folder in which you will apply your folder action to. Remember, the folder you select for this action will trigger your workflow each time you add an item to it. So you want to create or select a folder for only those purposes.

Name Your Folder

macauto 87   The Awesome Automation Guide for Mac Users

If you want to follow my example, name your folder, “Resize 570px”. We?re going to create a workflow in which any photo added to your designated folder will automatically get resized to 570 pixels.

Scale Images Workflow

macauto 88   The Awesome Automation Guide for Mac Users

For this Folder Action workflow, select Photos in the Automator Library. Scroll down and locate an Action called “Scale Images.” Drag it over the workflow area.

Add a Copy to Finder?

macauto 89   The Awesome Automation Guide for Mac Users

When you select the Scale Images Action, Automator will ask if you want this action to make a copy of the item before it scales it. If you?re fairly new to this type of process, you might choose “Add” to be on the safe side.

Scale Images Action

macauto 90   The Awesome Automation Guide for Mac Users
  1. In the pop-up menu of the Scale Images Action, select whether you want to this Action to scale by pixel size or to scale by percentage. For this tutorial, we’ll choose “To Size (pixels)”and type the number 480 or 570.
  2. Next, click the Options button and click the box, “Show this action when the workflow runs.” This is a very useful option because it allows you to change that default size number that you entered into the field above. If you think you will not change that number when it runs simply leave the box unchecked.

Move Finder Items

macauto 91   The Awesome Automation Guide for Mac Users

Now go back to the Automator Library and select the Files & Folders category. Scroll down and select the Move Finder Items Action.

macauto 92   The Awesome Automation Guide for Mac Users

Move the Action to the workflow area. By default, this Action will move the scaled image to your Desktop. But you can select another folder in your Finder.

macauto 93   The Awesome Automation Guide for Mac Users

In the case of this workflow, you cannot run and test it in Automator. So save and name it.

Now find an image and drop it into the folder you applied your Folder Action to. Give Automator a few seconds and it will scale the image.

The workflow will first ask if you want to change the default settings and then it will run the rest of the workflow. You don?t need Automator open and running in order for this workflow to work.

Create a Service Menu Workflow

In the last section we learned how to use a Folder Action to automatically scale an image, but suppose you want a way to do this process a little faster using a keyboard shortcut.

Well, there are a few other ways you can trigger Automator actions. As we learned in the first Automator lesson, we could save our Scale Image Action as an application, which means when we drop an image onto the application workflow, it will trigger the image scaling process.

Another method is to use the Services Menu, which enables you to access and trigger your workflow from the menu of any relevant application. In addition, you can create a custom keyboard shortcut for your workflow.

Open Automator

macauto 94   The Awesome Automation Guide for Mac Users

Open Automator and select the Service template.

Setup for Services

macauto 95   The Awesome Automation Guide for Mac Users
  1. Change the first pop-up menu to “images files”
  2. Change the second pop-up menu to “any application,” if it’s not already set that way.

This means your service workflow will be available only for image files, and it will be available in any application.

Scale Images Action

macauto 96   The Awesome Automation Guide for Mac Users

Add the same Actions we used in the previous Folder Actions tutorial.

Save Service Action

macauto 97   The Awesome Automation Guide for Mac Users

As with Folder Actions, Services Actions cannot be tested and ran inside of Automator. So give your action a name, and it will be saved to the Services menu in Preferences. Click Save.

Locate Action

macauto 98   The Awesome Automation Guide for Mac Users

Go to System Preferences and click on Keyboard. Then click on Services and make sure your “ScaleImage” Action is listed and checked.

macauto 99   The Awesome Automation Guide for Mac Users

To run this Service action, you would select the image, which in this case will probably be somewhere in your Finder, and then select the icon of the image file you want to scale. Go to Finder > Services >ScaleImage, which triggers your workflow.

Rescaleing Images Using the Action

macauto 100   The Awesome Automation Guide for Mac Users

You could also access your “ScaleImage” workflow by right- or Control-clicking on your image file and selecting your workflow in the shortcut menu that pops up.

Keyboard Shortcut

macauto 101   The Awesome Automation Guide for Mac Users

If you double-click on “ScaleImage” in Services, you can also add a keyboard shortcut, which allows you to activate your workflow.

Worth the Effort?

Putting together workflows, especially ones more complex than we covered in these tutorials, may seem like a lot of work. But keep in mind, once your workflow is complete and running the way you like, it will save you from performing repetitive and sometimes tedious tasks.

Other Sample Automator Workflows

The following are a sample of quick and easy Automator workflows. MakeUseOf.com has published several articles for similar Automator hacks.

See the references at the end of this guide for additional tutorials.

Spotlight Tag

macauto 102   The Awesome Automation Guide for Mac Users

Use this shortcut to quickly apply tags to files.

Paste In New Email

macauto 103   The Awesome Automation Guide for Mac Users

These two Actions can be used to paste the current content of your clipboard into a new mail message. I use this workflow to email an editor to let her know when a new article I wrote is posted. The workflow will include her email address, the date, and the title of the article, copied and pasted from my clipboard. When the workflow is launched, the latter information gets automatically included in the message.

Notice in the sample above I include what is called a date variable, which can be found in the Variables Library of Automator. When the workflow runs, it will create a new message with the current date stamped into the Subject heading.

Email URL

macauto 104   The Awesome Automation Guide for Mac Users

This workflow is similar to the one above. Select the URL of the current webpage and then run the workflow from the Services menu. It will create a new email message with the URL pasted into it.

Change Desktop Background

macauto 105   The Awesome Automation Guide for Mac Users

Running this workflow automatically changes your desktop background. You could make several separate workflows featuring your favorite backgrounds, and execute them when needed.

Change File Names

macauto 106   The Awesome Automation Guide for Mac Users

I use this action to batch change file names. Remember, when you check the “Show this action when the workflow runs,” box, it means that you will be able to customize the settings before the actions runs.

macauto 107   The Awesome Automation Guide for Mac Users

When you select one or more files, this workflow will copy those files and put them into a new folder. You can name the folder before it?s saved to the desktop or to another designated place in your Finder.

Combine PDFs

macauto 108   The Awesome Automation Guide for Mac Users

This workflow will copy and combine different PDF documents into one and will save the resulting file. Save it as an Application.

Learning More About Automator

The previous section only scratches the surface of Automator„s capabilities. Though what you essentially need to know about Automator has been presented in this guide, there are several resources for learning more about the program.

One of the best introductory sources is Automator for Mac OX 10.5: Visual QuickStart Guide, by Ben Waldie.

Official Automator Website

macauto 109   The Awesome Automation Guide for Mac Users

When you choose Automator > Display Automator Website, it will download the official Automator website which includes tutorials and workflows that you can download and run.

Photoshop Automator Actions

macauto 110   The Awesome Automation Guide for Mac Users

Writer and photographer Ben Long offers a collection of free Automator workflows for use with Photoshop CS. He sells a professional pack of workflows, but he provides sets of workflows for free, for Photoshop CS 2 through 5.

Navigate to the bottom of this page to download the free actions.

Apple Mailing List

macauto 111   The Awesome Automation Guide for Mac Users

Join this group to put yourself on the Automator mailing lists. There is also an archive of lists on this site where you can get some Automator ideas from. You can also access this list by choosing, in Automator, Help > Join Automator Mailing Lists.

Mac Automation Made Simple

macauto 112   The Awesome Automation Guide for Mac Users

Ben Waldie posts a monthly podcast of Automator and AppleScript tutorial videos that are very easy to follow, with some really great ideas.

MakeUseOf.com Articles About Mac Automation

Guide Published: December 2010

DOWNLOAD THIS GUIDE

PDF

The comments were closed because the article is more than 180 days old.

If you have any questions related to what's mentioned in the article or need help with any computer issue, ask it on MakeUseOf Answers—We and our community will be more than happy to help.