Books, PDFs Playlists?
Working with a script to get all the names of the playlists in iTunes, I noticed that two playlist names popped up in the latest iTunes 12.1 that aren't actually visible in my Playlists: "Books" and "PDFs". Here's a script that illustrates:
tell application "iTunes"
get every playlist whose name = "Books"
--> {user playlist id 60870 of source id 80}
get every playlist whose name = "PDFs"
--> {user playlist id 60873 of source id 80}
end tell
While I almost certainly have had "PDFs" playlists in the past, this doesn't appear to be some artifact from a past library. These playlists aren't in the XML either, but they have persistent IDs and low index numbers. I tried using AppleScript's delete command to remove them but it didn't work, which leads me to believe these are hard-coded and are supposed to exist. Not sure what this is about (iTunes does use invisible playlists from time to time) but it may be inconvenient and inaccurate if you use a script that lists playlists.
UPDATE: Kirk speculates that ebooks may be returning to iTunes.
iTunes 12.1
Apple has released iTunes 12.1 with fixes to device syncing and a new widget for controlling iTunes in Notification Center.
Things fixed: selection object for selected tracks in Audiobooks library works, reference to Audiobooks library via "get view of front window" command works. Things not fixed: View Options for CD display, Command-I shortcut for CD "Get Info". More as it develops.
NEW: Playlists Info
Playlists Info will display a sortable list of playlists in the current library (or in the selected source) along with their size, time and number of tracks. I've been finding this handy for eyeballing playlist sizes when managing music between iTunes and devices.
Additionally, the script can export a text file listing that information.
More info and download is here.
UPDATED: Batch Export Playlists v1.4
iTunes can only export a single playlist at a time using the File > Library > Export Playlist... command. My mouse finger's inter-phalangeals are achy just thinking about exporting more than a few that way. Batch Export Playlists v1.4 will export each selected plain, Smart, and Genius playlist as individual XML or M3U files to a user selected directory. Such files can be re-imported into iTunes again later or into other devices or apps.
As a bonus, Smart playlist XML files can be exported as two files, with one containing just the Smart criteria.
This latest version adds a heirarchical view for Playlist Folders which more closely emulates iTunes' playlist view and has some minor tweaks for better compatibility with OS X 10.10 and iTunes 12.
More information and download is here.
NEW: Duplicate Playlist Folder as Playlist
iTunes turns fourteen years old today which makes it about a month older than this website. And I think I've only just noticed that Playlist Folders don't have a duplicate command. (Technically, Playlist Folders were introduced in September 2007 with version 5.0. I'm still surprised I hadn't noticed. I probably just forgot. Yeah. That's it.) Recently, I wanted to get rid of a bunch of Playlist Folders and dump their tracks into plain playlists and I figured a duplicate command might do that.
I suppose it's easy enough to just select all the tracks in a selected Playlist Folder and use "Playlist From Selection" (Shift-Command-N) but I also wanted to delete the original Playlist Folder in the same swoop. And doing all that that turns into a mittful of keypresses and mouse-arounds. Which makes my scripty-sense tingle.
Duplicate Playlist Folder as Playlist will copy all the tracks in a selected Playlist Folder to a new "plain" playlist, essentially duplicating the tracks as viewed when the Playlist Folder is selected.
Optionally, it will delete the selected source Playlist Folder and its contents (of course, the tracks remain in your library, but any playlists and sub-Playlist Folders it contains will be deleted).
Codesigned, free, and nagless, more info and download is here.
NEW: Remove Leading-Trailing Spaces
Remove Leading-Trailing Spaces will remove any number of extra space characters at the beginning and ending of chosen tags (Name, Artist, Album Artist, Album, Composer, Genre, Grouping and Show) in the selected tracks.
Selected tags are remembered between launches.
iTunes 12 won't let you add leading or trailing spaces to a text tag in the Get Info panel so these sorts of anomalies are likely to be the result of tagging by another means (by editing a tag directly in the iTunes browser window, for example, or by using another application).
Blanking the Genre Tag in iTunes 12
Kirk has found a bug in iTunes 12 whereby selecting a batch of tracks and deleting their Genre tag via the Get Info panel inserts 8 spaces instead of empty text into each track's Genre tag. This creates a Blank Genre that is actually displayed and selectable in Genre lists.
This AppleScript will correctly delete the Genre tag of each track in a selection:
tell application "iTunes"
set sel to selection
repeat with thisTrack in sel
tell thisTrack to set its genre to ""
end repeat
end tell
Also, any number of other scripts that can edit the Genre tag, like Multi-Item Edit, will get the job done.
MacVoices Podcast
Chuck Joiner invited me to join him on his MacVoices podcast. We talk about iTunes and AppleScript (of course) and obsessive-compulsive music organization, among other topics.
Dupin v2.8.4 Released
Over the weekend, I released a version of Dupin that was basically a simple maintenance release. However, it was then brought to my attention that a bug had been in existence since v2.8.2 which errantly moved files to the Trash when using Dupin to remove tracks from a playlist. This isn't an often-used featuremost users just want to delete the tracks and Trash the files from the entire librarybut you can imagine the problem this would cause when the last thing you expected while just removing tracks from a playlist is to find that the files had been Trashed as well.
I have fixed that issue in version v2.8.4 of Dupin.
UPDATED: Sundry Info to Comments v4.0
iTunes knows some stuff about your tracks but won't let you see it other than via the Get Info panel because there are no columns in the browser window to accommodate it. We can fix that.
Sundry Info To Comments v4.0 can copy your single choice of filename, file path (location), file's parent folder path, file creation date (YYYY-MM-DD HH:MM:SS), current playlist, volume adjustment, start time or stop time (HH:MM.SS), artwork size (WxH), purchaser name or purchaser account ID to choice of Category, Comments, Description or Episode ID tag of each selected track. By putting data in one of these available tags it can be visible and sortable or used with Smart Playlist criteria.
Setting up to copy the Apple ID to the Episode ID tag of the track selection.
This latest version adds the track's start time, stop time and artwork size as info to apply; adds the Episode ID tag as a potential target tag; adds user-enterable separator-text field when appending to extant tag text; now stays active and frontmost until Quit; has minor compatibility adjustments for OS X 10.10.
Sundry Info To Comments is for OS X 10.8 and later and is free to use full-featured for ten day, $1.99 thereafter. More info and download is here.