Email Attachments with Automator

Emailing files is pretty much as common as breathing these days. If you use Mac OS X 10.4 and Appleis Mail application, you can eliminate some of the drudgery that goes along with sending attachments thanks to Automator. Setting up an Automator workflow to compress a selected file, create a new email, and attach your file to it only takes a couple of minutes to build, but can save you hours each year. Hereis how:

Setting Up Your Workflow
Start by launching Automator. Itis in the Applications folder on your hard drive. One itis up and running, we only need to find four Automator actions to set our workflow up.

    - Click Finder in the Library column to weed out the Actions we wonit be using.
    - Drag the Get Selected Finder Items Action from the Action column workflow area. Thatis the big empty space in the right half of the window.
    - Drag the Create Archive Action below the Get Selected Finder Items Action.
    - Now click Mail in the Library column. The rest of the Actions we need will show up in the Actions column.
    - Drag the New Mail Message Action below the Create Archive Action.
    - Finally, drag the Add Attachments to Front Message Action below the New Mail Message Action.


The Email Attachment workflow in Automator.

You should now have four Actions strung together, ready to do your bidding. Before your new workflow is truly automated, however, we need an easy way to activate it.

    - Head on up to the menu bar and select File>Save As Plug-in.
    - Give the workflow an appropriate name, like "Email File."
    - Choose Finder from the Plug-in for pop-up menu.
    - Click the Save button.

Using Your Workflow
To use your newly created workflow, just Control-Click (Right-Click for multi-button mice) a file or folder, slide on down the contextual menu to Automator, and then select your workflow from the fly-out menu. Your workflow will automatically compress your selection in .ZIP format, create a new email message in Mail, and attach your compressed file to it.


Control-Click a file or folder, then choose your workflow from the Automator contextual menu.

Now all you have to do is add an email address and send your attachment on its way.

Variations On a Theme
This Automator workflow is easy to customize for your needs. The Create Archive and New Mail Message Actions include fields letting you add more information that Automator will use when your workflow runs. The default name for your .ZIP file, for example, is "archive." You can change that in the Create Archive Action.

The New Mail Message Action includes everything you need to set up a pre-addressed message, including To, CC, and BCC fields, as well as Subject and Message fields. If you have more than one email account, you can choose which one the workflow uses from the Account pop-up menu.

Automator workflows are fairly simple to create and modify, and they can save an amazing amount of time by performing repetitive tasks for you. Thereis also more than one way to set up a workflow, so feel free to experiment and build something that does exactly what you need.