Your best friend for file transfer.
FetchNOTE: Fetch 5.8 does not offer Automator support. The documentation below is only accurate for Fetch 5.7.7 and earlier. Automator support may return in a future release of Fetch.
Fetch includes a number of actions for Mac OS X's Automator, allowing you to create simple workflows that can automate a variety of Fetch tasks.
This help topic describes all the Fetch Automator actions in detail. If you are not familiar with Automator, you may want to start by reading the introduction to using Automator with Fetch help topic, which has a brief overview of Automator and examples of creating Automator workflows that use Fetch.
The Fetch Automator actions can be found in the Internet category.
The available Fetch Automator actions are:
Delete Fetch Items - This action deletes the Fetch Items passed in as input. You can have the action ask for confirmation before deleting the items.
Input: Fetch Items. Result: nothing.
Download Fetch Items - This action downloads the Fetch Items passed in as input to the folder you specify on your Macintosh. Items are always downloaded using the Automatic download mode.
Input: Fetch Items. Result: Files/Folders.
Filter Fetch Items - This action passes only the Fetch Items that meet the specified criterion on to the next action. You can filter by name, name extension, item type (file, folder, or alias), size, modification date, and permissions. The Name and Name Extension filters are case insensitive.
Input: Fetch Items. Result: Fetch Items.
Generate Fetch Item Report - This action generates a text report listing information about the Fetch Items passed in as input. This action does not create a text file on its own; to see the report, you must pass the results to another action that accepts text input, such as the TextEdit "New TextEdit Document" or "New Text File" actions.
Input: Fetch Items. Result: Text.
Get Fetch Folder Contents - This action returns the Fetch Items passed in as input plus the Fetch Items inside any folders in the input items. If the "Repeat for each subfolder found" box is checked, then the contents of all nested folders will be included in the results as well.
Input: Fetch Items. Result: Fetch Items.
Get Selected Fetch Items - This action gets the selected Fetch Items from the frontmost Fetch transfer window and passes them to the next action. It requires a Fetch transfer window with one or more items selected.
Input: The selected items. Result: Fetch Items.
Get Specified Fetch Items - This action passes the Fetch Items specified in the list to the next action. You can add items to the list by clicking on the Add (+) button, which displays a dialog similar to the New Connection dialog. You can either enter the information necessary to specify an item, or you can choose one of your recent connections or shortcuts from the pop-up menus. If a password is required to access the items, the password should be stored in your keychain in order to allow the workflow to operate without further input. Otherwise, Fetch will prompt you for the password and the workflow will be on hold until you enter the password.
Input: None, or Fetch Items. Result: Fetch Items.
Move Fetch Items - This action moves the Fetch Items passed in as input to a different remote folder, and then passes the items (in their new location) to the next action. You can choose to move the items to the items' parent folders; your home folder; the root folder of the server; a sub-folder of the items' current folder; or to a specific folder in your home folder, the items' parent folder, or the root folder.
Input: Fetch Items. Result: Fetch Items.
Rename Fetch Items - This action renames the Fetch Items passed in as input. You can rename the files by adding a date and time to the existing names, adding text before or after the existing names, changing the case of the letters in the names, numbering the files sequentially, or finding and replacing specific text in the file names. Each renaming method offers a variety of options for how the renaming should be done. At the bottom of the action, you will see an example of what the new names will look like after you perform this action.
If you want to change the extensions of a batch of files, you can use the "Replace Text" pane of Rename Fetch Items to accomplish this.
Input: Fetch Items. Result: Fetch Items.
Set Fetch Item Permissions - This action sets permissions on the Fetch Items passed in as input, and then passes the items to the next action. You can specify different permissions for files and folders, or just set permissions for one or the other. To specify the permissions, you can either enter three-digit UNIX equivalent strings directly in the text fields, or you can choose the permissions from the pop-up menus to the right of the text fields. This action will ignore alias items and leave their permissions unchanged.
Input: Fetch Items. Result: Fetch Items.
Upload Files - This action uploads the files and folders passed in as input to the specified Fetch folder and returns the newly created Fetch Items as the result. You can either enter the connection information for the destination, or you can choose one of your recent connections or shortcuts from the pop-up menus. (If Fetch is not already running, there may be a delay when you click the recent connections or shortcuts menus while Fetch is opened.) If a password is required to open the connection, the password should be stored in your keychain in order to allow the workflow to operate without further input. Otherwise, Fetch will prompt you for the password and the workflow will be on hold until you enter the password. In addition to specifying the connection information for the destination, you can choose the upload format that should be used when uploading the items. After the upload is complete, the action outputs a list of the files (but not the folders) that were uploaded.
Input: Files/Folders. Result: Fetch Items (files only).
In addition, you can also take advantage of Fetch's extensive AppleScript support in Automator by using the Automator "Run AppleScript" action.
You can save Automator workflows as applications, allowing you to easily create droplets to perform Fetch actions. For instance, create a workflow that consists of an Upload Files action configured for your favorite upload location, and save the workflow as an application. Then you can just drag files and folders to the droplet, and they'll be uploaded to your server automatically without requiring further input. If you want to automatically change the files' permissions or rename the files after uploading them, add a Set Fetch Item Permissions or a Rename Fetch Items action after the Upload Files action.
Most of the Fetch actions support the "Show action when run" option, which displays an action's options as a workflow runs, so that you can change the options from their default settings when you run the workflow.
For more examples of things you could do with Automator and Fetch, see the introduction to using Automator with Fetch and more examples of using Automator With Fetch help topics.
Related topics: