Include subfolders in an automator workflow?

<Thanks HD for showing me the way in>
I created an automator workflow to backup one of the folders on my desktop.
The problem is, if I add a file to one of the subfolders automator does not backup the folder contents. The workflow works only if I add an item to the folder in the top of the heirarchy. What should I do?
the applescript generated by automator is
on adding folder items to this_folder after receiving added_items
tell application "Macintosh HD:Users:myUserName:Library:Workflows:Applications:Folder Actions:Backup2Tiger.app"
open added_items
end tell
end adding folder items to

Hi,
You'd have to attach the action to the subfolder as well. Control-click on the sub-folder, choose Attach a Folder Action from popup menu, and then navigate to your folder action.
It might be possible to modify the folder action so that it attaches itself to any folder dropped onto the original. I'll have a play with it this evening.
Cheers,
H

Similar Messages

  • Automator workflow to include/exclude startup items?

    Anyone know of an Automator workflow (or third-party app) that can easily include/exclude a startup item?
    I sometimes want an app to be a startup item and sometimes don't. So it would be convenient if I could just run a script to include/exclude it.
    Not critical... just for convenience sake.
    Any ideas?
    Thanks.

    Can you give us an example of some of the things you would like to do this with? I used to, for example use login items to mount the drive with my iTunes music. I stopped doing it that way and now mount the drive when iTunes launches. Depending upon whats being done perhaps a series of Automator actions could be used to create specific stings for specific tasks.

  • Automator workflow need

    Hi,
    I need a workflow to do the following:
    I have a folder that contains a certain number of files and subfolders, some of them having names ending with "_cc"
    I need to create a copy of this folder, including subfolders and files, then replace in all files and folders the "_cc" by "_ca"
    Then, I need a new copy of the folder, including subfolders and files, and replace in all files and folders the "_ca" by "_cs"
    Repeat and rinse, but with the following strings: _da, _de, _es, _fr, _fi, etc...
    The objective is to obtain, starting from a unique folder, a set of copies where each instance of _cc has been replaced by the relevant "extension"
    Any idea? i managed to create a workflow to do one copy (even though it was surprisingly difficult to ensure that folder names and file names were modified correctly, i had to use 3 different Change name actions), but can't find a way create the multiples copies and apply the rename actions correctly, either by using a loop and variables or sequential duplicate+renames.
    Any help/advice appreciated,
    Thanks in advance,

    I will look at this more tomorrow to be sure but here is what I think needs to happen.
    1. Build an application (Automator or Applescript) that Quits QuickTime). It's a one step workflow in Automator that uses the Quit Application step set to QuickTime. Save the workflow as an application.
    2. Set up an AHP scheduled recording. At the bottom of the schedule tab is a setting that says "When Timer Finishes" and a drop down for scripts. Use the drop down to select the script you just created.
    Haven't tested it yet but it should work.

  • Automator Workflow Fails with Cryptic Error Message

    I'm updating an Automator workflow for OS X Lion that I initally developed and used, without issue, in OS X Tiger. The workflow asks for a name, creates a folder for the name, takes a digital image with a Nikon D50 connected to the computer, and saves the image to the new folder. This aspect of the workflow works fine.
    I then have a prompt asking if we should take another. If the user says "yes," the script should take another image and save it to the folder. This is where I run into an issue. When I attempt to add another "Take a Picture Action" into the workflow, I get the cryptic (at least to me) error message in the attached screenshot.
    Here's the text:
    "Cannot update for observer <AMWorkflow 0x400458ac0> for the key path "parameters.name" from <TakePicture 0x403e3b0a0>, most likely because the value for the key "parameters" has changed without an appropriate KVO notification being sent. Check the KVO-compliance of the TakePicture class."
    The language of this error would seem to indicate a bug. Any thoughts on a fix or the means to report to Apple?

    The subject of this post is a bit misleading. The workflow wasn't failing while I was running it, but rather when I was editing it and trying to include another 'Take a Picture' action in the same workflow.
    The workaround I found was to use a 'Loop' action on the 'Take a Picture' action. It's a bit more elegant and doesn't require multiple 'Take a Picture' actions in the same workflow.
    Nonetheless, what does this error message mean?

  • Old Toad's automator workflow to backup Library6.iPhoto database

    Dear Old Toad,
    I just today downloaded your workflow to backup the iPhoto database file, and am having problems making it work.
    When I run it, either from the dock or the script menu, it launches Automator but then closes without doing anything. I don't get a confirmation screen, and no copy of the database is created.
    So I opened it in Automator to see if editing it would help, even though my library is already named iPhoto Library and stored in user/pictures. When I dragged it onto the Automator window, there was only 1 action (Get Specified Finder Items) instead of the 4 that show up in the ReadMe. When I dragged it onto the Automator app to open it, I got nothing.
    I downloaded it via Firefox 3.0.1 and got a 1.1MB zip, and I tried downloading it twice in case it had corrupted in the download, but no change with the second try. Downloaded from here:
    http://web.mac.com/toad.hall/ToadsCellar/ToadsCellar.html
    Running OS 10.4.11, iPhoto 7.1.5, on a G4.
    Something else I can try?
    Thanks,
    Daiya
    Message was edited by: Daiya

    Yes. Run the application like you would use the Save command in other applications, often. Running it again will overwrite the current backup copy with a new backup that will include all changes you've made to your library, new pictures, deletions, slideshows, books, etc.
    I suggested keeping it in the dock so you can quickly run it after any changes you've made to the library. Being in the Dock makes it more convenient than having to go into the Application folder and launching it from there.
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto (iPhoto.Library for iPhoto 5 and earlier) database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've created an Automator workflow application (requires Tiger or later), iPhoto dB File Backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. It's compatible with iPhoto 6 and 7 libraries and Tiger and Leopard. iPhoto does not have to be closed to run the application, just idle. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.
    Note: There now an Automator backup application for iPhoto 5 that will work with Tiger or Leopard.

  • Automator Workflow

    Hi
    I have created a workflow for automator to send me an email for birthdays coming up in the next 2 weeks, if i save this as an app it runs fine
    But when is put an event into iCal to alarm and open either the automator workflow or application, it doesnt work
    I am at a loss as to why ?
    Any clues ! (Its on OSX Snow Leopard 10.6 and iWork 09)
    Regards
    Dave

    Unless I am mistaken that first action is actually Find Address Book Items in disguise. Once dropped in place the name changes to either Find People or Find Groups depending upon whether it is set to groups or people. That seems to be the step that is causing problems for me. When I remove it the new workflow sends.
    Here's what I have right now although it does not give me the option of searching two months ahead like one of my previous workflows did. I added a blank line after Stop If iInput is Empty just to make it easier to read.
    Find People with Birthdays
    Send Birthday Greetings
    Send Outgoing Messages
    Stop If Input Is Empty
    Find People With Birthdays
    Get Contact Information
    New Mail Message
    Send Outgoing Messages
    The block of steps that includes Stop If Input Is Empty sends a birthday greeting to people having a birthday. The second block sends me a confirmation email with the contact information of the people who were sent greetings. If you want to see what the original workflow looks like check out http://www.atpm.com/12.08/automator.shtml

  • Accessing Automator workflow from *within* iPhoto

    I have quite a few Automator workflows that I’d like to apply to a number of selected images right within iPhoto’s main window.
    Is there any other way than the usual export/re-import?

    Using that Automator workflow will add another layer of jpeg compression to the file and reduce it a fair amount. There's an applescript that will convert to sRGB without reducing the file size. You can download it from Toad's Cellar. It will convert all files within an folder that's dropped onto it. If the file reduction isn't of concern to you then use the Automator workflow. I have one on Toad's Cellar that will add the sRGB profile to all files within a folder and its subfolders. You could do the entire Originals folder in the library in one pass that way. You can download it and see if it differers from you workflow in any significant manner.
    NOTE: Neither of the two above will work with grayscale files. There is one that will convert files to jpg, RGB mode, and embed the profile available at Toad's Cellar, however.
    I may be preaching to the choir here but here's some tips on using PS with and within iPhoto:
    Using Photoshop (or Photoshop Elements) as Your Editor of Choice in iPhoto.
    1 - select Photoshop as your editor of choice in iPhoto's General Preference Section's under the "Edit photo:" menu.
    2 - double click on the thumbnail in iPhoto to open it in Photoshop. When you're finished editing click on the Save button. If you immediately get the JPEG Options window make your selection (Baseline standard seems to be the most compatible jpeg format) and click on the OK button. Your done.
    3 - however, if you get the navigation window that indicates that PS wants to save it as a PS formatted file. You'll need to either select JPEG from the menu and save (top image) or click on the desktop in the Navigation window (bottom image) and save it to the desktop for importing as a new photo.
    This method will let iPhoto know that the photo has been editied and will update the thumbnail file to reflect the edit..
    NOTE: With Photoshop Elements 6 the Saving File preferences should be configured: "On First Save: Save Over Current File". Also I suggest the Maximize PSD File Compatabilty be set to Always.
    If you want to use both iPhoto's editing mode and PS without having to go back and forth to the Preference pane, once you've selected PS as your editor of choice, reset the Preferences back to "Open in main window". That will let you either edit in iPhoto (double click on the thumbnail) or in PS (Control-click on the thumbnail and seledt "Edit in external editor" in the Contextual menu). This way you get the best of both worlds
    2 - double click on the thumbnail in iPhoto to open it in Photoshop. When you're finished editing click on the Save button. If you immediately get the JPEG Options window make your selection (Baseline standard seems to be the most compatible jpeg format) and click on the OK button. Your done.
    3 - however, if you get the navigation window that indicates that PS wants to save it as a PS formatted file. You'll need to either select JPEG from the menu and save (top image) or click on the desktop in the Navigation window (bottom image) and save it to the desktop for importing as a new photo.
    This method will let iPhoto know that the photo has been editied and will update the thumbnail file to reflect the edit..
    Message was edited by: Old Toad

  • Batch processing from Bridge: checking the "include "Subfolders" box

    My request is simply to make this function work.
    This would help my workflow enormously. If the processing simply reproduced the folder structure on the destination drive, as selected in the "Destination: Choose" dialogue, that would be completely adequate. TIA.

    Thanks, Omke; ignore that Q. I posted on the "Features" thread.
    I just ran a quick test on Dr Brown's 1-2-3, but selecting it via "Scripts"; amazingly, the "Include subfolders" check box appears.
    The only part that does not seem to work is that the results of the processing seem to be in one folder only (rather than the processing following the folder structure of the folders, or, in the case of using 1-2-3 from Bridge, TIFFs appearing in one folder marked "TIFFs" and JPEGS in their own folder).
    Not a big problem, but if there is a way to reproduce the folder structure of the *Source* files and subsolders, I will be 100% happy!
    Cheers, kl

  • Automator workflow portability

    I created an Automator workflow on one machine, including some actions in BBedit. I saved it, transferred a copy to iDisk and downloaded it to another machine. On the second machine only part of the workflow showed up. All of the BBedit search and replace commands in the workflow were absent. I left it as is, transferred it back to iDisk, and downloaded it to the original machine, and it appeared in its original full form! I've repeated the cycle a couple times with consistent results. What's going on? The file structures etc. on the two machines are all but identical.
    I'm new to Automator.
    1.6GHz G5, 1.4GHz Mini, 1.2GHz eMac, 400MHz TiBook   Mac OS X (10.4.7)  

    Did you download and install the BBedit actions on
    the second machine?
    I didn't consciously do that on either machine, but the actions showed up in the Automator menu on both machines. I simply downloaded and installed BBEdit 8.2.6 on both machines.
    Another strange thing is that the Workflow takes a long time to launch on the machine where it does work.

  • Include subfolders

    I couldn't find a discussion on automator anywhere. Hence I am posting this question here since automator workflow generates an applescript.
    I created an automator workflow to backup one of the folders on my desktop.
    The problem is, if I add a file to one of the subfolders automator does not backup the folder contents. The workflow works only if I add an item to the folder in the top of the heirarchy. What should I do?

    Hi dj9027,
    The Automator forum is here . It would help if you described exactly how your workflow is structured, which actions you're using and in what order.
    Cheers,
    H

  • Automator workflow help: Moving files

    I am have trouble with an automator workflow. My ultimate goal is to create a image capture plugin that will create a dated folder with two subfolders for 'PNG' and 'JPG' files. Thus far I've been able to get the creation of the folder hierarchy I'm trying to create but when once action to import files from my device pulls the files I want I'm having trouble sperating the two file types into there subfolders.
    As it stands my work flow consist of the following actions and variables:
    *Image Capture plugin work flow*
    1. New Dated Folder (Action)
    2. Set Value of Variable (Variable)
    [Variable: 'Folder' So that I can ref back to this variable]
    3. New Folder (Action)
    [Folder name: 'PNG' using the 'Folder' variable to store this new folder]
    4.Set Value of Variable (Variable)
    [Variable: 'PNG']
    5. New Folder (Action)
    [Folder name: 'JPG' using the 'Folder' variable to store this new folder]
    6. Download Pictures (Action)
    This is the point in wich I get stuck.
    I've tried a few Files & Folders actions but I'm unable to parse by file extension.
    (I've tried both Filer Finder Items and Find Finder Items actions set to the file extension but keep pullling all my files to one sub folder or the other.)
    Any advice would be much

    The Filter Finder Items action should do it - for example, get the original items (and save for later), filter/move one set of items, get the original items back and filter/move another set of items, etc.  Be aware that the period is not a part of the extension, and watch out about mixing previous results into the current set if input items.  Each action has an Ignore Input option (where appropriate) - for example, when getting the original items from a variable, ignore the input so that the previous results (e.g. the path of moved items) don't get mixed in.

  • How to apply multiple automator workflows to one file

    Hi everyone,
    I've set up a few workflow applications to automate the process of making packshots from PDF files. The way those roughly work is they create a temporary copy in a folder, open a Photoshop droplet that executes all the actions on the file, and then save the finished product in a "finished" folder.
    However, we frequently need to deliver multiple packshots made from the same file. I was asked to make one automator app that allowed us to drop the PDF version on it, resulting in the multiple types of packshots in the "finished" folder, together with the original PDF.
    The way I have this set up right now is as follows:
    1) Copy the original PDF file to the "finished" folder
    2) Execute the first automator app
    3) Execute the second automator app
    This seems simple enough, and does work in 10.6.8. When I try it on a different computer in our studio though, with 10.7 installed, I get various errors:
    - Sometimes it says an error occured within one of the automator apps, while the app works fine when running it seperately (on all computers).
    - Sometimes it says something like "An error occurred while converting the data" when moving on from the first application to the second application
    - Sometimes I'll get an error message in the log, saying:
    *** -[_NSArrayl objectAtIndex:]: index 0 beyond bounds for empty array
    What I got from this is that it's actually not getting the right input it requires (or not getting any input, since it's an empty array). However, the previous task is set to "return the task input" (our systems are Dutch so excuse me for any discrepancies in translations please), and the resulting output that I get seems to be what I want the next automator application to use. Below is a screenshot of the error message:
    What I've tried:
    - I read somewhere that the newer versions of Automator require the action "Retrieve selected finder items" between them. I've tried using this in various ways (between all other actions/tasks, only before the second application to be run and before both applications to be run), but with no success. The problem I have with these is that, during the applications, it moves the files around, thus apparently selecting those folders as well.
    - Building an entirely new workflow on the newer system
    - Using "Start application" instead of "Execute Automator workflow". This results in Automator saying that it did execute the workflow while nothing happened.
    - Using "Ignore input" for the second application. This also results in Automator saying that it executed the workflow while nothing happened.
    So right now, I'm pretty stumped as to how to get this combination of apps to work in 10.7. Any solutions or workarounds are most welcome.
    Thanks in advance!

    Yes, angelanna. You can merge or split your video file via FCP sequence.
    ahaah, maybe I think angelanna would like to get the resulting file with MTS format because he mentioned “No need to be compressed”. Are you asking for this, angelanna?
    If so, a simple MTS files managing and editing tool  is needed. Maybe you can have a try the Mac version of Aunsoft Final Mate for managing HD camcorder footages. I just downloaded its free trial version and it offers a simple way of garping footages directly  from camcorder. And also it provides a attractive feature to join flawlessly and split accurately native MTS files for video file output with original MTS format.
    Maybe this is the tool cwhich an help you out, angelanna.
    Enjoy your video.

  • Cannot manually select Automator workflows in iCal

    I know That the Way, Apple intends that we create an Automator workflow as an iCal alarm is to create a new iCal alarm in Automator, and once you save it it automatically creates a new event in iCal. Unfortunately, that's not the way I want to work… I already have dozens of iCal alarms configured, and I'm trying to prep them for Mountain Lion: the currently open AppleScript's but all of my Apple scripts need to be converted to Automator workflows for Mountain Lion. So I was hoping to quickly duplicate previous iCal workflows, then reselect them from within existing events in iCal. Sadly, all of my iCal Automator workflows appear as greyed out in my File Open dialog when attempting to select a new file to run within my iCal alert.
    I don't want to have to delete all of my iCal alarms and start over creating them anew. Perhaps I am missing something simple?

    https://discussions.apple.com/docs/DOC-4082
    http://www.macworld.com/article/1165641/how_increased_mac_security_measures_will _impact_applescript.html
    https://discussions.apple.com/thread/4139323?start=0&tstart=0
    according to the first link I can save the applecript as an application. It doesn't answer why my automator workflows are greyed out when I try to select them, but maybe I'll just try saving as applications... sounds simpler.

  • Automator workflow no longer works on 10.7

    Hi.  I've been using an Automator workflow for years:  it opens iTunes, looks for a specific radio station, sets iTunes volume, sets Computer volume, starts iTunes playing and runs a small Applescript script to close the folder if it was open.
    This has been running for years.  Upgraded to 10.7 and it stopped working.  It seems to launch, but nothing happens.
    I recreated the same workflow, and I can run it:  it states that every step is "Completed".  But it really doesn't work!!!
    What should I try next?  (Windows 8???)

    Hi Frank.  Thanks for the response.
    (Mentioning Windows 8 was a joke, as I'm sure you know! ;-)
    Here's what the workflow looks like;  you'll note the "all green" log at the bottom!
    By the way, when I run it, iTunes does launch;  but it doesn't play anything.  And there IS a WCPE entry;  it's a radio station that is in the list of radio stations/Classical and that entry has also been copied to one of my playlists. 
    The workflow was created as an application and it's run when I power up the Mac.
    Thanks for your interest and advice!

  • Getting File Name in Automator workflow - combine PDF

    I am using Automator to combine 2 PDF files.
    I would like to inherit one of the file names in the new PDF and append a standard text to the front of the file name.
    I am not sure how to do this. I can combine the PDFs the way I would like, but I am not sure how to plick the file name.
    my workflow is as follows.
    Folder Action targets folder where 1st PDF is added(I want this FILE NAME).
    Ger Specified finder item selects 2nd PDF to be combined.
    Sort Finder Items makes sure the new PDF pages are ordered properly.
    Combine PDF Pages combines the pages.
    Move Finder Items saves the files where i want it.
    Name single item is whre i thought to add my standard text plus the variable of FILE NAME.
    Open File in mail to set up my email.
    Anyone can help with this?
    thanks,
    Aaron

    Here is an automator workflow that does something similar so I believe you can adapt to your needs.  This workflow is setup as a service workflow. It will combine PDFs in the order in which they are selected/clicked via the Shift key.  The default name of the combined output file will be the name of the first file clicked.  Automator can be activated by CTRL clicking any of the selected PDFs.
    1. Service receives PDF files in Finder
    2. Automator Action: Run AppleScript
    on run {input, parameters}
              display dialog "Files will be combined in the order selected via the Shift key" as text
              return input
    end run
    3.. Automator Action: Trim input items
    keep the first one
    you will need to download and install this autotmator action from here:
    http://www.menace-enterprises.com/Files/Automator/Actions/Trim%20Input%20Items.d mg
    4.  Automator Action: Run AppleScript
    (* Note & Definitions
    This Applescript extracts the basename of the first selected file without its .pdf extension
    "path_basename_ext" is full path and name, e.g. User/desktop/file.pdf
    "NmExt" is filename with extension, e.g. file.pdf
    "baseName" is the base filename without extension, e.g. file
    "Ext" is the file's extension, e.g. pdf
    on run {input, parameters}
              set path_basename_ext to input
              tell (info for path_basename_ext) to set {NmExt, Ext} to {name, name extension}
              set baseName to text 1 thru ((get offset of "." & Ext in NmExt) - 1) of NmExt
      baseName
              return baseName
    end run
    5.  Automator Action: Set Value of Variable
    define baseName as the variable
    6.  Automator Action: Get selected finder items
    Options: check ignore input
    7. Automator Action: Combine PDF pages
    choose Combine by appending
    8. Automator Action: Move Finder Items
    choose To: Desktop
    Options: check show this action when workflow runs
    9. Name Single Items
    choose Basename only to: baseName
    Options: check show this action when workflow runs
    10. Open Finder Items

Maybe you are looking for