Bulk Refreshing Data in Apple Music

Sometimes I use external programs to update my Music files; specifically, I like using MusicBrainz Picard to add extra information. Once you change the info externally, you need to tell Music to re-read the file and update. You can always “Get Info” on each file individually, if you only have a few files to refresh. But, if you have a lot of them, just hi-light them and run this little snippet of AppleScript:

tell application "Music"
	set sel to selection
	if sel is {} then return
	repeat with aTrack in sel
		if class of aTrack is file track then refresh aTrack
	end repeat
end tell

I found this code out on the net years ago, and I cannot find it again, so I don’t know who to give credit to. But it still works just fine if you paste it in Script Editor and then save it into ~/Library/Music/Scripts/Refresh.scpt (or whatever name you like). This will make it appear as a menu item in Music, and let you refresh as many tracks as you have hi-lighted.

Leave a Comment