I like to keep my iTunes library organised and all files well-tagged, so I often spend enjoyable yet unreasonably long amounts of time editing all the ID3 tags manually. Call it OCD or perfectionism, that's how I roll. Thankfully, iTunes is rather convenient for basic operations like batch-changing tags or artworks, but it only goes so far. The problem is that for much music I get, the tags have to be edited for each track individually, taking into account details like numbers and such. Here's an example of what I mean:
Notice that files have no embedded track numbers, and are numbered within the track name instead. This picture is more to my liking:
To achieve this within bare iTunes, one would have to input track numbers by hand and then remove the ХХ -
from each name. Now, I can of course do this by repeatedly mashing the favoured combo (holding ⌥: ← → → ← ⌫ Left Mouse Button), but when I need it for 300 tracks across numerous albums, this turns into a problem.
So I want to have a quick way for my Mac to do this for me. I imagine something like a script that extracts track numbers from file names or name tags through use of wildcard characters and applies them to respective ID3 tags while removing numbers from names. Finder has a handy built-in dialog for batch-renaming, but as far as I know it doesn't have this specific formatting functionality. I tried Automator and MusicBrainz Picard, but they don't have that either.
Is there anything that can be of help? Script libraries for Automator or Terminal commands? Maybe some handy AppleScript functions I don't know of?