Neon Goat MP3 Report Generator
A customizable program to scan a list of (sub)directories, creating a report from an HTML template. Also calculates various statistics and each song's playing time. Supports ID3 and ID3v2 tags. Should work on any perl-ized OS; see homepage for demo - http://mp3report.sourceforge.net
All options can be configured through the command line, see mp3report.pl --help for more info. You may also want to modify the hard coded defaults at the top of the program file.
See documentation.html for information on customizing your own template file.
Usage: mp3report.pl [options] [directory...] --help shows this help screen --printmode uses a smaller font for printing --title=TITLE sets the title used in the report --outfile=OUTFILE file to write report to, '-' for STDOUT --template=FILE file to use as report template --stdgenres use standard genres instead of winamp genres --id3v2 enable id3v2 support (experimental) directory... dirs to scan (subdirs included)
You should be able to run mp3report.pl directly after decompressing it: tar xfzv mp3report-1.0.0.tar.gz cd mp3report-1.0.0 ./mp3report.pl --help If your perl interpreter isn't in /usr/bin/perl, you'll need to change the first line of mp3report.pl If you'd like to install the MPEG::MP3Info perl module so that other programs can use it, it is available at http://search.cpan.org/search?dist=MPEG-MP3Info.
By creating your own HTML file or modifying one of the provided templates, you can customize the output of MP3 Report Generator. These are the various identifiers that MP3 Report Generator can look for in a report:
This is either 1 or 2, depending on the
--printmode flag. If printing mode is on, the idea is that the font size should be a
little bit smaller so that it looks better on paper. To make sure this
field does something, use
<FONT SIZE="$t_fontsize"> in your HTML code.
Used for the HTML
<TITLE> tag as well as the first line of the report, and is set by specifying
--title=SOMETHING on the command line.
The local date and time when the report was generated.
The list of parent directories that was scanned in the report. Each
directory is separated by
<BR> so that they are on seperate lines and indented.
The total number of directories and subdirectories scanned in the report.
The total number of MP3 files included in the report.
The total size of all MP3 files included in the report combined. This is formatted into ``x.xx GB (y.yy MB)''.
The total playing time of all songs combined. This is formatted into an English sentence (4 days, 3 hours, 2 minutes, 1 second).
The total time it took to genereate the report. This is formatted into an English sentence (4 days, 3 hours, 2 minutes, 1 second).
The average size of the MP3s in this report. This is formatted into ``x.xx MB''.
The average playing time of a single song in the report. This is formatted into an English sentence (3 hours, 2 minutes, 1 second).
The filename that the report is being written to.
The filename of the template that is being used.
Either ``Yes'' or ``No'' depending on whether the
--printmode flag was specified.
Either ``Yes'' or ``No'' depending on whether user specified custom directories to scan on the command line.
Either ``Standard'' or ``WinAMP'' depending on whether or not the user
Either ``Yes'' or ``No'' depending on whether the
--id3v2 flag was specified.
The current directory that is being scanned.
The current sequential number of the item found.
The filename of the item found.
The size of the item found. This is formatted into ``x.xx MB''.
This will either be
#EEEEEE (white or light gray) depending on whether or not the current item number
is even or odd. This is used to make the cell color in tables alternate to
make the report easier to read. In order for this to work, your HTML code
must look something like
The playing time of the song found, formatted into ``XX:YY'' (minutes:seconds).
The total number of seconds in the current song.
The MPEG version number of the current MP3, usually 1.
Either ``Stereo'' or ``Mono'' depending on the number of channels in the MP3.
The MPEG layer number, usually 3.
The bitrate of the current MP3 in kbps.
Either ``Copyrighted'' or ``Not copyrighted'' depending on the MP3's copyright flag.
The frequency of the current MP3 in kHz.
The song's ID3 title, maximum 30 characters.
The song's ID3 artist, maximum 30 characters.
The song's ID3 album, maximum 30 characters.
The song's ID3 year, maximum 4 characters.
The song's ID3 comment, maximum 30 characters (28 if the ID3 tag also contains a track number).
The song's ID3 genre. You may disable WinAMP genres by specifying the
The song's ID3v1.1 track number (if present), maximum 2 characters.
ID3v2.3.0 (or later) tags are also supported. To enable ID3v2 support, use
--id3v2 flag on the command line. The following is taken from
TEXT: Lyricist/Text writer
TMED: Media type
RVAD: Relative volume adjustment
RBUF: Recommended buffer size
TOAL: Original album/movie/show title
TRCK: Track number/Position in set
IPLS: Involved people list
MLLT: MPEG location lookup table
TKEY: Initial key
APIC: Attached picture
SYTC: Synchronized tempo codes
TPOS: Part of a set
TRSN: Internet radio station name
UFID: Unique file identifier
TRSO: Internet radio station owner
TENC: Encoded by
TRDA: Recording dates
SYLT: Synchronized lyric/text
WOAF: Official audio file webpage
LINK: Linked information
COMR: Commercial frame
TBPM: BPM (beats per minute)
PCNT: Play counter
TOFN: Original filename
WOAR: Official artist/performer webpage
WOAS: Official audio source webpage
TFLT: File type
TSRC: ISRC (international standard recording code)
TPE3: Conductor/performer refinement
TPE4: Interpreted, remixed, or otherwise modified by
MCDI: Music CD identifier
TDLY: Playlist delay
TORY: Original release year
TCON: Content type
TCOP: Copyright message
OWNE: Ownership frame
TXXX: User defined text information frame
GEOB: General encapsulated object
TSSE: Software/Hardware and settings used for encoding
PRIV: Private frame
TIT1: Content group description
TALB: Album/Movie/Show title
TIT2: Title/songname/content description
TIT3: Subtitle/Description refinement
POSS: Position synchronisation frame
GRID: Group identification registration
USLT: Unsychronized lyric/text transcription
ENCR: Encryption method registration
TOWN: File owner/licensee
WORS: Official internet radio station homepage
ETCO: Event timing codes
WCOM: Commercial information
AENC: Audio encryption
WCOP: Copyright/Legal information
WPUB: Publishers official webpage
WXXX: User defined URL link frame
Much thanks to Chris Nandor and contributors to MPEG::MP3Info... it saved me a lot of time :) And to Larry Wall for such a great language. Hello to MMT, UCLA LUG, cX, and of course the DJs of Mister Balak's Neighborhood!
http://www.bdc.cx/software/mp3html/ (a similar type program written in C -- very nice)
Neon Goat MP3 Report Generator v1.0.0 - January 27, 2000 Copyright (C) 2000, David Parker, Neon Goat Productions. 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. See COPYING or http://www.gnu.org for more information. David Parker email@example.com http://www.neongoat.com http://mp3report.sourceforge.net