How to "Batch Edit" the "Comments" column in Finder?

Discussion in 'macOS' started by lip5016, Oct 24, 2014.

  1. lip5016 macrumors regular

    Jul 11, 2014
    Hello! I was looking to see if anybody knew of any quick/easy apps that can "Batch Edit" the "Comments" column in Finder?

    I would like the same kind of functionality as you see in iTunes.. I have many music sample libraries that I am trying to keep organized by entering in specific keywords, such as tempo, key, etc..

    It's a super pain in the ass to click through every single item in the Finder and right-click, "Get Info", click in the Comments section, close that window, repeat..

    I have the app "Rename" already, but it doesn't seem to be able to "erase" pre-existing Comments.. Does anybody know of a faster way to streamline this? I want to be able to basically select a whole bunch of them, right-click like in iTunes and edit the parameters across the whole bunch..

    Can anybody help?
  2. chown33 macrumors 604

    Aug 9, 2009
    Sailing beyond the sunset
    AFAIK, Finder doesn't support batch editing on any column.

    You could probably write yourself a Service using Automator, add it to Finder's contextual menu, and run it using a right-click and selecting the Service. Or you could assign a Shortcut key to the Service, which will appear under the Finder menu > Services > YourServiceHere.

    The Automator Service would receive selected files as its input. It would have no output.

    Within the Service, you'd write an AppleScript that changed each item's comment. Do this:
    • Open AppleScript (it's in Utilitites).
    • File > Open Dictionary... > choose in list.
    • Observe a "Finder.sdef" window opens ("sdef" = "Scripting Definitions").
    • In left column showing Suites, select Finder Items.
    • Observe middle column shows commands ("C" in a blue circle) and classes ("C" in a purple square).
    • Select the class whose name is item.
    • Observe right column shows the class's properties ("P" in purple square).
    • Also observe large text area below 3-column area displays all the properties and their descriptions.
    • Find the comment (text) property in the list.
    This shows you what target to address with your AppleScript. Specifically, you'll need to tell Finder to change the comment property for each item the script receives as input.

    If you want to add something to the comment, you'll have to get the item's comment as text or string, append the text you want appended, then set the item's comment to the resulting string.

    You can learn about scripting in general, how to make Automator Services, how to tell Finder what to do, etc. by referring to any tutorial on Automator and/or AppleScripting. I strongly recommend making simpler Automator Services and AppleScripts first, so you can learn the individual parts of the overall task you want done.

    If that's more work than you want, then maybe you can find an app on the Mac App Store that will batch edit comments for you. I think it's unlikely to be integrated with the Finder, but I could be wrong.

    Another possibility is an app that lets you catalog, sort, file, attach keywords, etc. and is completely separate from Finder. For example, some of the Finder replacement apps might do this. Or maybe there's an app for catalogging files in general, that only provides keyword tagging, and doesn't do anything else. Years ago I used an app designed for catalogging Compact Discs that worked great for this kind of arbitrary "tag any file with any keyword" catalogging and retrieval.

Share This Page