cleantags is a simple program to clean extraneous tags from audio files.
I use EasyTag to tag my music files very particularly. Unfortunately, EasyTag doesn't allow one to strip tags not shown in the UI (see this feature request) so it's fairly common for me to fire up a music player to find unwanted tags still in my music files.
cleantags solves that. It gets rid of all ID3 and Ogg tags not processed by EasyTag, plus it will strip any APE tags from files that also have an ID3 or Ogg tag (which are super annoying when present).
First, make sure you've got Mutagen installed.
cleantags.py passing any files or directories you want to clean
up. All files in passed directories (and subdirectories, recursively) will be
Note that until you get a feel for what it's going to do to your music, you may
want to run it in interactive mode by passing
-i, which tells you what tags
it's going to remove and allows you a chance to say no.
cleantags.py --help for the full usage details.
EasyTag is sometimes weird about how it stores its comment field in the ID3
tag. 99% of the time, it sets the lang to
XXX, but very occasionally it
doesn't (I've seen
eng, three spaces, and other varieties). cleantags will
go ahead and remove any comments with lang not set to
XXX, but because of
the uncertainty it also issues a notice so you can check its work manually.
If your music has ReplayGain ID3 tags that you want to preserve, you'll
want to uncomment the lines near the top of
cleantags.py so the ReplayGain
tags are whitelisted.
Note that by default mp3gain will put ReplayGain data in APE tags, and
since cleantags tries to strip APE tags, it will destroy your ReplayGain data
unless originally tagged with
mp3gain -s i. Just a heads up.