I’ve always found it annoying that you can’t make pattern-like changes to the titles of a batch of songs, in the spirit of batch renaming files (admittedly, a bit of a science itself). So, I figured, maybe that’s finally a reason to learn how to use Automator, and the time spent on it might come in useful later on if I ever want to create another Automator workflow. Needless to say, I gave up 1, except: Automator does let you just package any AppleScript as a Service (although only since Snow Leopard, I believe), and that’s exactly what I did.
Download here: iTunes batch rename workflow
Install: unzip, double click install.app
Requirements: OS X 10.6 Snow Leopard (I believe)
Use: select files in iTunes, go to menu iTunes > Services > iTunes batch rename
When invoked from the Services menu, a dialog box asks for a Perl substitution pattern of the form s/expr1/expr2/ etc, where expr1 is a Perl regular expression to be replaced by expr2. The given expression is applied to all song titles, not the file names.
For example, if your song titles all contain the name of the artist, say
Telephone (Lady Gaga)
Bad Romance (Lady Gaga)2
you can simply strip it by using the pattern s/ \(Lady Gaga\)// . The backslashes just escape the brackets, which are reserved characters in Perl; if you’re not familiar with Perl regular expressions, find a nice tutorial on them via the search engine of your choice.
If I see that people are at all interested and download the workflow, I might start implementing more features (of course you might also just do it yourself…). The first one on my list is to put the songs’ actual filenames in a variable so one can parse them to fill in blank song titles. A semi-natural second follow-up would be the ability to modify the artist field as well. I’m thinking here of files with a filename containing both artist and title, but devoid of metadata.
- It seems to me that anything I am interested in doing with Automator can either only or much more quickly be done in AppleScript or other script languages… and that even though I know almost nothing about AppleScript. And btw, I just wanted to try this footnote plugin. ↩
- No, I’m not a fan, in fact, I couldn’t care less… ↩
0 Responses
Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.