Mass tagging with Mp3tag
Jump to navigation
Jump to search
WORK IN PROGRESS
Requirements
- Track files and their parent folders need to be named as follows:
- Each track file name starts with the track number.
- Each tracks parent folder name contains somewhere:
- for a single-CD album, the album barcode number;
- for each CD in a multi-CD album, the album barcode number, followed by dash (minus), followed by the CD number.
- Examples:
My Music\El rey del compas (1941-1943) 828766933420\1 El rey del compás.mp3
My Music\40 Grandes Exitos (CD1 of 2) 8427328146067-1\01 Patotero sentimental.mp3
My Music\40 Grandes Exitos (CD2 of 2) 8427328146067-2\01 Porteño y bailarín.mp3
Setup
- Go here to download Mp3tag (freeware supported by donation) V2.39f or later, install and launch.
- Select the following two lines (mouse to the start of the first, then click and hold as you drag to the end of the second):
$filename(,ansi)$loop(%dummy%)$regexp($regexp($regexp(\%_directory%\%_filename_ext%,.*?(\d{12,14})(?:-(\d+))?.*?\\(\d+).*,$1-$2-$3),^(\d+)--(\d+),$1-1-$2),\\(.*)\\(.*),Error: track and/or album number missing from filename "$2", foldername "$1") $loopend()
and click Edit | Copy.
- In Mp3tag, click Tools | Options (you'll get the Mp3tag Options dialog box) and then in the left-side list click Export.
- Click the starred page icon (you'll get a dialog box) and click OK (you'll get a Notepad window).
- In the Notepad window, click Edit | Select All and then Edit | Paste (all lines will be replaced by the lines you copied above).
- Click File | Save.
- Leaving the Notepad window open, switch back to the Mp3tag Options dialog box.
- In Export file name type c:\mp3tag.txt .
- Uncheck Show selection dialog.
- Click OK, again click Tools | Options, and click New Configuration (workaround for Mp3tag V2.38f bug, awaiting fix).
- Click OK (the dialog box will close).
Step 1 - Retrieve tag data
- Launch Mp3tag if not already running.
- Click File | Change directory... and select the folder containing your album folders. To add further folders, use File | Add directory....
- Click File | Export (you'll get a dialog box) and click Yes (you'll get a Notepad window showing a list of track references).
- Look for any lines saying Error: track and/or album number missing.... For any you find, either:
- correct the reported file/folder names to meet the naming requirements above e.g. using Windows Explorer, then go back to 2. above, or;
- exclude them: in Mp3Tag, click Path (for helpful grouping), select each corresponding track and press Delete, then go back to 3. above.
- Click Edit | Select All and then Edit | Copy.
- Go to http://tools.tango.info/tagging4.php.
- Click in the (unlabelled) text box, click Edit | Paste, and click Submit. You'll get a tag list in the lower text box.
You've retrieved the list of tag lines for your tracks.
Step 2 - Save the tag data
- Click on in the lower (unlabelled) text box (this will the tag list) and then click Edit | Copy.
- Switch back to the Notepad window (containing the track references list, still selected) and click Edit | Paste (the contents will be replaced by the tag list).
- Inspect the tag list for any line starting Error::
- Error: track not found... means tango.info has no data for this track - the track will simply be skipped.
- Error: input not in recognised format () on the very last line is due to a known and otherwise harmless bug, and may safely be ignored (improvement planned.)
- Error: followed by anything else means a serious problem has occured - do not proceed.
- Click File | Save.
You've saved the tag lines for your tracks.
Step 3 - Put the tag data into your track files
- Switch back to Mp3tag.
- Click Edit | Select all files
- Click Convert | Text file - Tag (you'll get a dialog box).
- In Filename enter c:\mp3tag.txt.
- In Format string enter
%dummy%;%dummy%;%album%;%BAND%;%discnumber%;%track%;%title%;%artist%;%genre%;%year%;%dummy%
- Click OK. You'll get a dialog box saying e.g. Tag extracted from text file ' c:\mp3tag.txt" and saved in 2024 of 2024 files.
- Verify the two numbers are the same. If not, you probably made a mistake in copying or pasting - click Edit | Undo and try again from Step 1.
You've put the tag data into your track files. Mp3tag shows you the result.
Please consider donating to Mp3Tag here.