Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages


home | help
MP3ID(1)	      User Contributed Perl Documentation	      MP3ID(1)

       mp3id - displays/edits id3 metadata (id3v1 and id3v2) in	mp3 files

       mp3id _file.mp3_...

       mp3id -[12qtvxXh] -c[12bcC] -- _file.mp3_...

       mp3id -A	_artist_ -L _album_ -T _track_ -N _tracknum_  _file.mp3_...

       mp3id -G	_genre_	-Y _year_ -C <comment> _file.mp3_...

       mp3id -ap _file.jpg_ -rp	_file.gif_ _file.mp3_...

       mp3id -p[aNALTGYCpPfF] -[iI] _file.id3_ _file.mp3_...

       mp3id -d[axbpzNALTGYC] -df _frame_ _file.mp3_...

       mp3id -e[abp] -ef _frame_ _file.mp3_...

       mp3id -af _frame=data_ _file.mp3_...

       mp3id -af _frame:key1=val:key2=:key3=file(file.dat)_ _file.mp3_...

       mp3id -rf _frame=data_ _file.mp3_...

       mp3id -rf _frame:key1=val:key2=:key3=file(file.dat)_ _file.mp3_...

       mp3id -[Ff]

       mp3id is	a command-line viewer and editor for id3 metadata in mp3
       files. ID3v1 and	ID3v2 are both supported, including access to extended
       ID3v2 metadata (pictures, lyrics, etc).

       Options are processed in	order, so you could do eg:

	mp3id -v -A Artist -L Album -N 1 -T Foo	foo.mp3	-N 2 -T	Bar bar.mp3

       Any options involving N,	A, L, T, G, Y or C refer to trackNumber,
       Artist, aLbum, Title, Genre, Year or Comment, respectively.

   General Options
       -1, -2
	   Show/modify ID3v1/ID3v2 tags	only. By default it does both v1 and
	   v2 tags.

       -q  Quiet (no output). This is the default if any changes are being

       -t  Terse output.

       -v  Verbose output. This	is the default if no options are supplied.

       -x, -X
	   View	extended ID3v2 frames. -X shows	all ID3v2 frames as extended
	   frames, including the basic ones (artist, album, etc).

	   If terse output (-t)	is selected, an	attempt	to summarise the
	   extended frames as tersely as possible is made.

	   Extended frames are separated by :. Simple extended frames are of
	   the form "framename=value".

	   Complex frames have a leading frame name, then a :. The elements of
	   the frame are enclosed in angle brackets (<>), separated by :, and
	   are displayed in the	form "elementname=value". The contents of
	   binary frames (eg _Data) is displayed as "<data>"

	   For instance, one simple and	one complex frame would	be displayed
	   as eg:

	    filename:ext:TSIZ=2000:APIC:<Picture Type=Other:_Data=<data>:MIME type=image/gif:

       -f  Summarise available ID3v2 frame types.

       -F  Show	a detailed listing of available	ID3v2 frame types.. This is
	   several pages long, so you may wish to pipe it to a pager such as

       -h  Shows a summary of command line options.

       --  Treat remaining command line	arguments as files to operate on, not

   Options to set basic	metadata (artist, album, etc)
       -A artist
	   Set Artist

       -L album
	   Set aLbum

       -T track
	   Set Trackname (song title)

       -N num
	   Set trackNumber

       -G genre
	   Set Genre

       -Y year
	   Set Year

       -C comment
	   Set Comment

   Options to add/replace extended frames
       To find out about available frame formats, see MP3::Tag::ID3v2-Data(1).

       For a quick reference, use mp3id	-f.

       -ap picfile
	   Add picture.

       -rp picfile
	   Replace picture. This will only replace the first APIC frame. If
	   there is more than one APIC frame in	the file, you will need	to use
	   the -rf option, below.

       -af 'frame=data'
	   Add a simple	frame. The data	field can be empty.

	   If necessary, you should enclose the	frame spec in single quotes
	   ('),	especially if there are	spaces or other	characters that	will
	   be interpreted by the shell.

       -af 'frame:key1=value:key2=:key3=file(file.dat)'
	   Add a complex frame.	The format is the framename, then a colon,
	   then	a list of fieldname=value, separated by	colons.	Field values
	   can be left blank.

	   If you want the contents of a file included in the field (useful
	   for binary _Data fields), surround the filename with	file(),	e.g.

	   If necessary, you should enclose the	frame spec in single quotes
	   ('),	especially if there are	spaces or other	characters that	will
	   be interpreted by the shell.

	   If all this is too much hassle, try -pf to enter frame details
	   interactively, with prompting.

       -rf 'frame=data'
	   Replace a simple frame. The data field can be empty.

       -rf 'frame:key1=value:key2=:key3=file(file.dat)'
	   Replace or merge a complex frame.

	   The frame format is the same	for adding frames (-af,	above).

	   If you omit any fields and the frame	already	exists,	they will be
	   taken from the existing version of the frame, otherwise it is an

   Importing and Exporting data
       When writing files containing pictures or binary	frame data, the
       filename	is created from	the basename of	the file (ie with the
       extension (eg .mp3) lopped off),	then a 2 digit number to distinguish
       multiple	frames from the	same file, then	a guessed extension. If	the
       frame contains a	MIME type field, the extension will be guessed from
       the MIME	type, if not it	will default to	.bin.

       For instance, the contents of the _Data field of	the first APIC frame
       with MIME type "image/jpeg" in foo.mp3 will be written to foo.01.jpg.

       -i file.id3, -I file.id3
	   Import data dumped with the -ea option (see below) from from

	   -I deletes the files	you have imported, including any files
	   included using the file() syntax.

	   The format for the .id3 export file is essentially the same as that
	   displayed by	mp3id -vx, except that instead of using	<data> as a
	   placeholder for binary frame	data (_Data etc), it uses the file()
	   notation to include data from a file.  See the -af option above for
	   more	details	on the file() notation.

	   Not all fields need to be present in	the import file, it will only
	   alter those mentioned in it.

       -ea Dump	(export) all id3 tag data to a file. The file will be have the
	   same	basename as the	input file, but	with an	extension of ".id3".
	   For example,	"mp3id -ea foo.mp3" creates the	file foo.id3.

	   This	file can be edited then	imported using the -i option (see

       -eb Extract all binary data stored in frames.

	   Some	frames (eg APIC, the frame for storing pictures) have elements
	   that	begin with _, usually "_Data". These elements are used for
	   storing binary data (eg picture data). This extracts	the content of
	   the binary data element for each frame that contains	one.

       -ep Extract all pictures	from file.

       -ef frame
	   Extract named ID3v2 frame.

   Deleting data
       -df frames
	   Delete named	frame

       -da Delete id3 tags.

       -dx Delete extended frames.

       -db Delete binary frames	(frames	containing elements starting with _,
	   eg _Data, which contain binary data).

       -dp Delete pictures. This will delete all APIC ID3v2 frames. If you
	   only	want to	delete the first picture, use:

	    mp3id -df APIC file.mp3

       -dz Delete id3 tags that	contain	no data.

       -dN Delete trackNumber.

       -dA Delete Artist.

       -dL Delete aLbum

       -dT Delete Track	name (song title).

       -dG Delete Genre.

       -dY Delete Year.

       -dC Delete Comment.

       -pa Prompt for all items.

       -pN Prompt for track Number.

       -pA Prompt for Artist.

       -pL Prompt for aLbum.

       -pT Prompt for Track name (song title).

       -pG Prompt for Genre.

       -pY Prompt for Year.

       -pC Prompt for Comment.

       -pp Prompt for a	picture	to add.

       -pf Prompt for an arbitrary frame to add	(simple	or complex).

   Copying and Comparing frames
       -c1 Copy	data from ID3v1	tag to ID3v2 tag.

       -c2 Copy	data from ID3v2	tag to ID3v1 tag.

       -cb Copy	data from best source. If an ID3v2 frame is set	and non-empty,
	   sets	the ID3v1 tag data to the same value, otherwise	attempts to do
	   the reverse.

       -cc, -cC
	   Compares ID3v1 and ID3v2 data.

	   If -cc is used, it allows for truncation caused by limited-length
	   ID3v1 tags, and only	compares up to the length of the ID3v1 tag

	   -cC is stricter, and	complains if there is any difference between
	   the tags.

       mp3id file.mp3
	   Display id3 tags in file.mp3	(same as mp3id -v file.mp3).

       mp3id -vx file.mp3
	   Display id3 tags in file.mp3, including extended id3v2 tags.

       mp3id -2	-da *.mp3
	   Delete all id3v2 tags in all	mp3 files in current directory.

       mp3id -A	artist -T album	-pN -pT	*.mp3
	   In all files	in the current directory, set the artist to artist,
	   the album to	album, then for	each file prompt for the tracknumber
	   and track title.

       mp3id -c2 file.mp3
	   Copy	id3v2 tag to id3v1 tag.	Some data may be truncated due to
	   limitations of the id3v1 format. See	MP3::Tag::ID3v1(3) for details
	   on the lengths of id3v1 tag data.

       mp3id -cc file.mp3
	   Compare id3v1 and id3v2 tags	and complain if	they don't match.

       mp3id -ea file.mp3
	   Extract all tag data	from file.mp3 and write	it in
	   human-readable/editable format to file.id3

       mp3id -i	file.id3 file.mp3
	   Import the tag data from file.id3 to	file.mp3

       mp3id -af 'COMM:Language=ENG:short=:Text=Hello World' file.mp3
	   This	is the long-winded way of adding a comment. This is equivalent
	   to mp3id -C "Hello World" file.mp3.

       mp3id -ap pic.jpg file.mp3
	   Adds	the picture pic.jpg to file.mp3. If there is already an	APIC
	   (picture) frame present, this will be added as (eg) APIC01.

       mp3id -af 'APIC:MIME type=image/jpeg:Picture type=Other:Description=A
       picture:_Data=file(pic.jpg)' file.mp3
	   This	is the long-winded way of adding a picture. It is equivalent
	   to the -ap example above (except that -ap sets the Description
	   field to the	filename of the	picture).

	   Note	the use	of file() to import the	picture	data from pic.jpg.

       mp3id --	-filename.mp3
	   Views the tags in -filename.	The -- option stops mp3id from
	   treating -filename as an option.

       mp3id -f
	   View	a summary of available ID3v2 tags and their associated data

       mp3id -F	| less
	   View	a detailed list	of available ID3v2 tags	and their associated
	   data	elements, piping through less(1) to show a page	at a time.

       This program makes heavy	use of the perl	module MP3::Tag(3), by Thomas

       None known. Please report any found to

       mp3-archive-tools(1), MP3::Tag(3), MP3::Tag::ID3v2-Data(1), mp3lint(1)

       Ian Beckwith <>

       mp3id is	part of	the mp3-archive-tools package.

       The latest version can be found at:

       Copyright 2003 Ian Beckwith <>

       This program is free software; you can redistribute it and/or modify it
       under the terms of the GNU General Public License as published by the
       Free Software Foundation; either	version	2 of the License, or (at your
       option) any later version.

       This program is distributed in the hope that it will be useful, but
       WITHOUT ANY WARRANTY; without even the implied warranty of
       General Public License for more details.

       You should have received	a copy of the GNU General Public License along
       with this program; if not, write	to the Free Software Foundation, Inc.,
       675 Mass	Ave, Cambridge,	MA 02139, USA.

perl v5.32.1			  2003-12-12			      MP3ID(1)


Want to link to this manual page? Use this URL:

home | help