As part of cleaning up my iTunes library, I want to clean up the Genres. I’ve been wanting to clean up my Genre’s in iTunes, since I am sure it will help with Genius Mixes as well as just make it easier to play certain types of music I may be in the mood for. When trying to find a quick way to do this, I decided I would just use whatever Wikipedia said was the Genre for that artist. I found too that Wikipedia will redirect usually redirect you to the page you need to go to as well (for example, will convert spaces to underscores as needed).
At some point, I would like to make this script also parse out the Genre text and apply it to the Artist in iTunes, but I didn’t take the time to figure that out yet. This at least saves me quite a few clicks and typing to load the page, where I then find the Genre (or decide which one I want to use if multiple), then just apply it to all songs by that artist in my library.
You could also run this through Automator as well, to possibly even create a service.
tell application “iTunes”
if player state is playing then
set theCurrentArtist to (artist of the current track)
tell application “Safari”
activate
open location “http://en.wikipedia.org/wiki/” & theCurrentArtist
end tell
end if
end tell