[ Home ] [ Photos ] [ Me ] [ Blog ]
[ Useful Bits ] [ Wasted Disk ] [ Hacks ]

Import iTunes Ratings     [ download ]

When I moved my iTunes music collection from Vista to OS X, I was surprised there was no way to bring over the the ratings I had given to each track as well. This was a major suck, as the playlists I listened to the most where "Smart Playlists" that used my ratings.

I first tried to implement this as an AppleScript, which is seriously the worst programming language ever. Not only that, but if you have a decent iTunes library, AppleScript can't load it. Think about that for a second: an Apple product cannot consume the data created by another Apple product. I'm sorry, but that's just bad.

Eventually I gave it a shot in Python & had a working solution in less than an hour.

Installing

  1. Install appscript.
  2. Download import_ratings.py.
  3. On the new computer, back up your "iTunes Music Library.xml" file.
  4. Copy "iTunes Music Library.xml" from the old computer to the new.
  5. Fire up Terminal & run python import_ratings.py "iTunes Music Library.xml"

<William Reardon> wdr1+web@pobox.com