Automator - Filter Finder Items filtering contents of sub folders

I have an external hard drive and I want to keep my iTunes music library automatically backed up on it. I am using automator to copy my most recent files to the external (run the script once a week). I let iTunes manage all my audio files, etc so I figured the created, modified, opened dates would be the best way to filter the items I want to copy over. The workflow is as follows.
1) Get Specified Finder Items (iTunes Library Music folder)
2) Get Folder Contents (All artist directories (Repeat for each subfolder found is NOT checked)
3) Filter Finder Items (ANY of Date Last Modified, Date Created, Date last opened in the last week)
4) Copy finder items (to my external hard drive)
I am having two problems.
1) If I play a song from my second hard drive iTunes copies it into it's directory when it opens... iTunes Music > Artist > Album > Song.mp3. The mp3's modified date, created date, and last opened date is the same as the file that got copied. The new Artist and Album directories that were created by itunes have current created dates (makes sense). However, the filter is still not catching it. Only if the mp3 is current will the filter catch it. I DON'T have 'Repeat for each subfolder found'... shouldn't the filter check for the folder's modified, created and last opened dates?
2) If everything works the way I want it to I see this to be a problem in the future. If I add an album by an artist that I already have an album for, the filter will skip it. Any suggestions on how I could handle this problem?
Thanks.

Found out that since Hebrew was set up first in the language option the filter on textual was failing. After I changed the order of the languages in the language preferences the file filter by name, extension etc… worked O.K.
Nati

Similar Messages

  • Is there a bug in Automator filter finder items?

    I'm trying to do a batch processing script and there seems to be a bug with items created earlier in the script.  For example, the 2brokegirls.jpg file was created earlier in the script and added to the main folder whose contents can be seen in the get folder contents action at the top.  however, the filter finder items misses that item when filtering by the extension ".jpg" which as you can see obviously appears at the top.  Is this a bug in Automator?  My guess is that the filter is using some spotlight indexing and that index hasn't been updated since the file was just added.  Does anyone know of a workaround?
    Thanks.

    I also have this problem. I am getting literally hundreds of emails each day althoug i have clicked all the radio buttons to not receive any emails in "my preferences... email notifications. THis is gumming up my Ipad, Iphone and email in box Help!!

  • Automator Filter Finder Items

    A very simple task, which I have attempted to figure out many times over the last few months; but my repeated attempts haven't been successful. This should be easy for someone to resolve…
    I would like to strip out all the files of a certain extension (.txt) from an hierarchy of nested folders, & move them to the Trash. (Told you it was easy!)
    Here's what I think ought to work:
    • Create an Automator Workflow
    • 'Ask for Finder Items' to select the topmost folder
    • 'Get Folder Contents' with 'Repeat for each subfolder found' — (the results successfully include all the relevant files)
    • 'Filter Finder Items': "find files where any of the following are true: file extension is .txt" — (I tried "txt" as well as ".txt")
    • 'Move Finder Items to Trash'.
    The files turn up (alongside loads of other junk) in the 'Get Folder Contents' step, & they are reported in the results; but when I try to filter out everything apart from the .txt files, so that only the .txt files remain, the filter reports no results.
    So the 'Filter Finder Items' action completes with no results, & with a warning that: The action “Move Finder Items to Trash” was not supplied with the required data.
    I think it must be something obvious, but I can't figure it out, & although I've searched extensively online, everyone else with similar problems has other complications which get resolved… so they lose interest just at the point where I think they're going to reveal the solution.

    You need to understand the issues here. Automator was released with 10.4 (Tiger), and many of the core automator actions date from that time.  This introduces forward-compatability problems: things that should work (and maybe did work) in 10.4 might not work as specified in 10.6, depending on if/how the underlying cocoa APIs have changed.  Now, in the best of all possible worlds, Apple would update automator actions with each new upgrade, but it's probably not needed for the bulk of the actions, and Apple may not be aware of problems that do exist with given actions (that depends on whether people filed meaningful bug reports on them).
    Don't be confused by the seeming simplicity of what I did: the Move Finder Items to Trash action probably uses cocoa file system APIs directly, whereas my applescript leverages the developed programmatic underpinnings of the Finder - the Finder has a built-in system for moving files in bulk, whereas the action is obviously moving files one at a time (which is where things are getting congested).
    Filter Finder Items seems to be a simple metadata search (just another use of the spotlight framework, which hasn't changed much since its inception) so I can't see any way in which it would fail.  it is, of course, limited by the same things that spotlight is limited by - it won't find material that's not indexed and may not do exactly what one always expects (e.g., may not recognize an extension as an extension unless the extension belongs to an app registered with the system) but other than that there's very little it can do wrong.  As a general rule, actions that deal only with manipulating automator data (e.g. modifying references passed from one action to the next) won't break.  You'll only see breakage with actions that need to access exterior frameworks that have changed significantly since the actions were created. 
    That's the best answer you're going to get: one can't prove a negative, so there's no way to demonstrate that FFI isn't broken.  it's easy enough to check for a given task, though - just run the workflow you have on a test folder without the deleting action, check the results window, and compare it to the results you expect (which you can gather by eye in a Finder search window, through an applescript, through an app that will report the number of files of given types in a folder…). 

  • Automator - Filter Finder Items bug?

    I've only started using Automator a few months ago, but now I ran into a problem, which I think is not my fault, but is a bug in Automator.
    Here's the scenario:
    What I have is a Folder Action on the Downloads folder, and the following list of actions in order:
    Get Finder Items: how.i.met.your.mother.s04e05.srt (this is for testing purposes)
    Filter Finder Items - if ANY of the following are true:
    Name contains "big.bang.theory"
    Name contains "how.i.met.your.mother"
    Name contains "fringe"
    etc
    I managed to find out that the same kind of container (here: Name) could not be used multiple times, because it gives no result in case "Any" of them are true. There is no way to test if any of these strings are present in the file name. I thought I could use this action like a function with "OR"-separated boolean parameters, but apparently that only works if I change the container type, e.g. I use Kind instead of Name. Meaning, if there is only one Name container, then it outputs the correct result (the .srt file, if the statement is true).
    So, did I do something wrong, or is this really a bug in Automator? If you have an alternate suggestion on how to solve this, please don't hold it back

    I have the same problem.
    I am trying to select ANY of the following extentions: JPG, PNG, TIFF and I get no output. While if I only select one extention I do get the right output for the extention selected.
    ANY of the following are true
                   File extention          is          JPG
                   File extention          is          PNG
                   File extention          is          TIFF
         ~~~no results produced~~~
    ANY of the following are true
                   File extention          is          JPG
         ~~~001.JPG, 002.JPG, etc..~~~

  • Automator's Filter Finder Items behaves incorrectly

    Can anyone confirm the misbehaviour of the Filter Finder Items in Automator when set to filter items whose date created is not in the last 7 days?  I have a workflow being used as a folder action to keep my downloads folder tidy but never runs right as it gets rid of content that I've just downloaded.
    Link to workflow: http://cl.ly/1S0h1I3m3r1t3l2a1W1J
    Insight would be appreciated.

    The only reliable way to do that would be to take an inventory of the filesystem, and compare it with an earlier inventory. I don't know of any easy way to do that with built-in tools. If you use Time Machine, there are third-party tools such as BackupLoupe that compare snapshots. Or you could try something like Uninstaller, though it's quirky and doesn't seem to be maintained much anymore.
    At an advanced level, there are UNIX tools such as mtree, which is built in, radmind, or tripwire, but you probably don't want to go there. I use radmind and mtree for different purposes, but they're not for the squeamish.

  • Filter finder Items... broken? (also request to help streamline script)

    Let me begin by saying that I've done the SAME THING for a long time with this Automator script, and it's worked flawlessly. I recently added some now automator actions (and later deleted them) thinking they were the culprit of why my "filter finder items" was showing no results, but I'm not sure at all at this point.
    Here's the script (that has been working fine until at least the 7th):
    It's long, so bear with me (I use this script to install custom Sims2 content when I download it:
    ("Get Specified Folder" uses the "Get specified finder items" action, I just didn't want to type that every time).
    New Folder: Recent (in my downloads folder)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains .package)
    Copy Finder items (to Recent)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains Sims2Pack)
    Move finder itmes (to my core download folder (they're generally in subfolders after downloading, as are the .package files)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains Sims2Pack)
    Copy finder items (to Recent)
    Get Specified Folder: Recent
    Create Archive (on desktop named Sims2)
    Rename (add date to end of file name)
    Rename (add time to end of file name)
    Get Specified Folder: Recent
    Move to trash
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains .package)
    Move finder items (to Sims2 Downloads folder, which installs the custom content, replacing any repeats)
    Get Specified Folder: my downloads folder
    Get folder contents
    Filter finder items (name contains Sims2Pack)
    Move Finder items (Sims 2 Packs folder within the downloads folder... these items must be installed into the game by double-clicking on them.)
    Get Specified folder: Desktop
    Get folder contents
    Filter finder items (name contains Sims2)
    Move Finder items (To Backup)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains MTS (most of the containing download folders (after they've been expanded by another automator script, have this at the beginning of the folder name due to where I commonly download my custom content)
    Move to trash
    And that concludes the script. I know it could probably be streamlined (another reason I'm posting the whole thing) but it worked until very recently, and I don't know what could cause it to no longer report results after filtering within the subfolders while within the main folder works fine.
    To clarify, it's recently been simply deleting the MTS folders and creating a "Recent" folder and archiving it but it's empty. So the script is not filtering for the Sims2Pack data nor the .package data as it used to.
    I haven't modified the script, and I've deleted all actions that I downloaded recently (backed them up in case they're not the culprit). Also ran disk permission repair but nothing was repaired in regards to Automator.
    Thanks.
    iMac Intel   Mac OS X (10.4.7)  

    Here is an update to the script, however filter continue to not work as it once did.
    New Folder: Recent (in my downloads folder)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains .package)
    Copy Finder items (to Recent)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains Sims2Pack)
    Move finder itmes (to my core download folder (they're generally in subfolders after downloading, as are the .package files)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains Sims2Pack)
    Copy finder items (to Recent)
    Get Specified Folder: Recent
    Create Archive (on in "to backup" named Sims2)
    Rename (add date to end of file name)
    Rename (add time to end of file name)
    Get Specified Folder: Recent
    Move to trash
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains .package)
    Move finder items (to Sims2 Downloads folder, which installs the custom content, replacing any repeats)
    Get Specified Folder: my downloads folder
    Get folder contents
    Filter finder items (name contains Sims2Pack)
    Move Finder items (Sims 2 Packs folder within the downloads folder... these items must be installed into the game by double-clicking on them.)
    Get Specified Folder: my downloads folder
    Get folder contents (repeat for each subfolder found)
    Filter finder items (name contains MTS (most of the containing download folders (after they've been expanded by another automator script, have this at the beginning of the folder name due to where I commonly download my custom content)
    Move to trash
    I removed the step where it was saving it to the desktop. If the filters ever work again, this should therefore go faster than before.

  • "Filter Finder Items" not working properly

    I'm taking my first crack at Automator, and while I've made good progress, one of the built-in actions, "Filter Finder Items", is just not behaving predictably. Basically, I'm doing the following:
    1) Get selected finder items - pulls a selected folder
    2) Set variable - this gives me a variable for the name of the folder we're working with
    3) Create a new folder inside the selected folder
    4) Get folder contents of selected folder
    5) Filter for three different file extensions - here's where my problem starts
    6) Move the filtered files into the new subfolder (though it really seems to be copying, which necessitates the following steps to get rid of the original files)
    7) Get contents of selected folder again
    8) Filter on the same three files extensions - this time it works properly
    9) Move filtered files to Trash
    For some reason, the first filter action doesn't seem to be working at all - if I have 15 files in the selected folder, but only three that match the filter, all 15 will be copied to the new subfolder. The second folder action will then, inexplicably, work exactly as it should and move the proper files to the Trash.
    Does anybody know why this action doesn't want to cooperate? Has anybody else seen something similar?
    Thanks for any hints/help.
    Rick
    Message was edited by: rnb2

    Saving the workflow as an application should be all that is needed, but the first action (the one that gets the items to work with) may not be correct for your usage. If the first action is *Get Selected Finder Items*, unfortunately the selection would be the application itself, since that is what was most recently selected.
    In this case, the application can be dragged onto the Finder's toolbar (where it will work with the current selection), otherwise the first action can be removed and the application used as a droplet (items dropped onto the application are passed to the workflow) or a Finder plugin.
    The first action can also be replaced with an *Ask for Finder Items* action (ignoring input).

  • Multiple Extension in Filter Finder Items

    Does anyone know how to make Filter Finder Items filter for more than one extension? For example, if I want to make a script filter for MOV, AVI, and WMV?

    Well, it sure would be nice if the filter action would do that for you directly, but since it doesn't there are a few alternatives. You can use a Run AppleScript action to do the filters, a Run Shell Script action to do the filters, or use a bunch of Automator actions that do each of the specific filters and combine the individual results:
    Tested workflow:
    1) Ask for Finder Items (Type: Files, Allow Multiple Selection, Ignore Input)
    2) Set Value of Variable (Variable: Source Items) -- store the original items
    3) Filter Finder Items (Whose: Name Extension is equal to mov)
    4) Set Value of Variable (Variable: MOV items) -- store filtered MOV items
    5) Get Value of Variable (Variable: Source Items, Ignore Input)
    6) Filter Finder Items (Whose: Name Extension is equal to avi)
    7) Set Value of Variable (Variable: AVI items) -- store filtered AVI items
    8) Get Value of Variable (Variable: Source Items, Ignore Input)
    9) Filter Finder Items (Whose: Name Extension is equal to wmv)
    10) Get Value of Variable (Variable: MOV items, Accept Input) -- add the previous filtered items
    11) Get Value of Variable (Variable: AVI items, Accept Input) -- add the previous filtered items
    12) View Results (or continue with the rest of the workflow)
    Note that the Accept/Ignore Input item will let you combine or isolate the action from the results of the previous one.

  • 'Filter finder items' by variable

    Hi,
    Is this just a flaw in Automator or am I being a n00b? All I want is to filter finder items (name) by a variable set earlier in the action. This should be a gimme, right? Wrong. No worky.
    Anyone know why / how to get this working ?
    thanks in advance

    An action needs to be written to use variables (specifically, a different kind of text field is used), and not all do. Several of Apple's actions are from a time before variables, so they probably just haven't been updated to use them yet.
    You might check out this macosxhints article, but it doesn't always work.

  • Automator - Filter Finter Items

    Hi guys... need some help!
    I'd like to create a simple workflow that would select my recent files (from a very big folder) from the past month (or two) and copy them into another folder! I've looked but there's no option (that I could find)....
    Can anyone help me ?
    Thanks in advance.
    Nuno.

    message sent to red_menace:
    Hi red_menace, Thanks ! I had a look at your webpage and found just what I was looking for. You've created an excellent Automator action that does exactly what I was looking for (Filter Finder Items by Age). I will certainly look more "deep" at you webpage. Thanks once more. Nuno

  • Automator: Copy Finder Items Question

    Hola,
    Quick question about the Copy Finder Items action in automator: the "replace existing files" option, how is sameness determined? In other words, according to what criteria does Automator determine that two files are the same, and so eligible for replacement in the destination folder when that option is chosen? For example, would file Mydog.doc, modified 10/14/05, 230k be viewed as the same thing as Mydog.doc., modifided 2/21/06, 150k?
    Cheers,
    stu

    As far as the Finder is concerned, the comparison is based on file name only.
    It doesn't care about file size or modification date. If the name is the same the existing file will be replaced.

  • Automator Copy Finder Items - file couldn't be saved error

    I have a simple automator sequence that suddenly stopped working for no apparent reason.  Copy Finder Items has started returning an error "the file xxx couldn't be saved to the folder yyy"  Happens for different files and folders. Can't see anythng that's changed.  Any ideas?

    I'm currently having the same issue, and have had it with mulitple automator scripts on multiple computers, but it's not fixing itseltf. Anyone know what this error could be?
    I've noticed that I get the above error most often after getting and then correcting  permissions errors in the same workflow. Any help would be most appreciated.
    Thanks!

  • Automator Open Finder Items Won't Work in Plug-In

    I'm having another Automator problem in Leopard.
    This time I have a workflow that is intended to combine PDFs selected in Finder and open the resulting document in Preview. The steps are:
    1. Get Selected Items
    2. Combine PDF Pages, Combine by appending pages
    3. Open Finder Items, Open with Preview
    The workflow runs fine if I'm running it from within Automator. When I save it as a plug-in, the Open Finder Items portion doesn't work. If I turn on Show this Action, I get a dialog box with a dropdown list of programs with Preview already selected along with Cancel and Continue buttons. Clicking the Continue button does nothing.
    As a test, I tried removing the Combine PDF Pages step from the workflow and saving it as a plug-in. My expectation is that this version would simply open the items selected in Finder. Unfortunately, that didn't work either.
    Anyone have a clue for me?

    I'm having a similar problem. When running from within Automator everything is fin, but the plug in doesn't get the finder items. Oddly, I have ONE old workflow that takes the word "folder" away from a file name. That one works fine, but doesn't require any action once I select it. It doesn't even open the automator show action dialog window to make any changes. Weird how this one is still working and the other ones won't.

  • Automator (move finder items)

    I have a service that moves finder items to a particular folder. Since I started using this I noticed I occasionally will need to move an item with the same name into this folder. Is there a way I can get the service to move the second item with the same name, but instead of overwriting the first item, have it add a -1 or something? If I open something like a zip file multiple times in finder, it creates the second one with a 1 after the name. That's exactly what I need. Any way to do that with a service like this?

    No, I didn't give up on the thread, I just went to work with what you gave me to see what I could do with it. It's just that you've been nothing but extremely helpful and patient with me in the past; and I started to feel like I was coming to the board, putting up my problems, and you do everything for me. I know you're here to contribute to the community, but I don't like to take advantage. I am making an effort to learn this stuff now, I just have to make baby steps!
    Okay, here is the deal with this item. I actually want to apply this with more than one operation, but the basic script or concept would remain pretty much the same. We create lots of documents like invoices, receipts, shipping labels, etc., that usually get saved as pdf onto the desktop. Then, they are named, often with the date and particular file name and finally moved into the proper folders. For example, shipping labels get saved to desktop with the default name of something like
    vty3RlsIK.LabelGenerationServlet.part
    Then I would change the name to something like
    12-31-2009USPSLabel.pdf
    Then, I would move it to the folder where we keep the shipping labels for records.
    So, the service I created actually does more than just moving the file. It goes like this:
    service receives selected pdf
    in finder
    name single item in finder item names (to: USPS_Label.pdf)
    add date or time to finder item names (before name, underscore separator)
    move finder items (to target folder)
    open finder item (with default application)
    The other ones I need would be similar, except they don't usually need to be opened afterward, just named and moved, for the most part. I figured I could continue to just use the name change function of automator before running the script, but if would run faster or more efficiently if that were also part of the script, I suppose that would be better. And I would like to be able to have the numbers go up through as many as I need. If it's a matter of just adding in all the possibilities of existing names up to the number I need, that's tedious work I don't mind doing now to save on having to name all these files in the future!
    Also, these files are always named differently, so the source file would need to just be selected file, not the actual name.
    Finally, I tried to play with the script to name the desktop like you said, but would it be something like
    set source_folder to folder (path to desktop)
    or
    set source_folder to (path to desktop)
    I still need to learn a little more before I understand the way that works. I am so used to only using the unix path, I like the ability to use (path to desktop) that's really interesting.
    I think I may have rambled a bit, but that should explain the details of what I'm trying to accomplish.
    thanks

  • Automator Print Finder Items always aborts

    I have an automator script to print a document two-sided that worked in Tiger, but fails in Leopard. I recreated the script from scratch, but the Print Finder Items step works for a while and then aborts the script.
    I've tried using Default Printer and a specific printer in the Print Finder Items step, but both have this problem.
    Is this a known problem? Is there a known workaround?

    Dale Boss wrote:
    Thanks for your offer, and I'd love to take you up on it, but I can't figure out how to post the workflow. I don't see a way to attach, and using the clipboard doesn't work.
    It's a duplexing script. It starts with Extract Odd&Even Pages (even) and then Print Finder Items (default printer). That second step fails. There's more to the script but that may be enough for you. If not, a hint on posting a workflow?
    just write down the sequence of actions and options that you use. It shouldn't take too long. I don't know any other way of posting workflows.

Maybe you are looking for

  • Embed Icons in List View?

    I have seen an Xcelsius demo where it appears icons (i.e. trend, stop light) are embedded on a row in a list view.  When the list view is scrolled, the icons move with the proper row. Does anyone have an idea of how this technique is accomplished?  (

  • Removing message in already picked up by adapter

    I have an invalid xml that has been picked up by the FTP Adapter in ProcessConnect. I can see the offending element that is not conforming to the xsd (in fact, this is the demo/tutorial, the HR placing Ad one). It's falling over translating the Nativ

  • Panasonic 32" LCD 60 vs.. 120 Hz's refresh

    Am purchasing my first flat screen HDTV. Don't want to pay a lot Have had good prior experience with Panasonic and 32" -40" is about right size. Am currently viewing an old Sony non-HD. Am a football junkie and don't want to experience jitters if ref

  • Can AS know if an desktop icon already exists in a location

    this code moves a file on the desktop to a specific location. tell application "Finder" set desktop position of alias "Macintosh HD:Users:Shawn:Desktop:The Matrix Effect - Video.webloc" to {1800, 1000} end tell Can you ask Applescript if an icon is a

  • Need WP implies that Oracle allow/certify 3rd party MML agent installation on Exadata

    Hi, I need WP that implies Oracle allow/certify 3rd party MML agent installation on Exadata.. I know its allowed but where is the paper mentioning this BR, Ammar