Posted Thursday, December 16, 2004

Culling an iTunes Library: Deleting Songs You Don't Play

On his must-read Mac 911 blog, my Macworld colleague Chris Breen recently fielded a question from a reader who wanted to know how to easily remove songs he never listens to.

Chris offered some great suggestions, and some readers chimed in with more.

No one has offered the following technique, though, so I'll add my voice to the chorus.

1. Create a smart playlist whose criterion is Play Count is 0.
(Variations: Play Count is less than 5. Last Played is not in the last 6 months. You get the idea: you want to tell iTunes to gather up songs you've either never played or haven't played in a while. UPDATE: And if you don't want to include songs you've bought, add another criterion: Playlist is not Purchased Music.)

2. In the Source area of the iTunes window, select the smart playlist.

3. To delete all the songs that iTunes has identified as, shall we say, neglected, choose Select All from the Edit menu and then press Option-Delete. When iTunes asks if you want to remove those items from the library, click Yes. When iTunes asks if you want to move those files to the Trash, click Yes again.

As an alternative to deleting all the songs, you can look over the smart playlist and delete tunes on a song-by-song basis.

The key to this technique is the Option-Delete keyboard sequence. Normally, iTunes won't let you delete a song from a smart playlist. That makes sense, since a smart playlist is one whose contents iTunes determines based on your criteria.

But holding down the Option key while pressing Delete overrides this behavior and tells iTunes to yank the song from your library.

Where's the Script, Doug?
This chore of cleaning out neglected tunes seems to be a perfect one for an AppleScript. I poked around Doug Adams' invaluable Doug's AppleScripts for iTunes site, but didn't find a script that does this job. Thwock! The ball's in your court, Doug!