Download shn2make here
The current version is 2.14
shn2make(1) shn2make(1)
NAME
shn2make - A tool for working with sets of shn and flac audio files
SYNOPSIS
shn2make [ options ]
DESCRIPTION
shn2make works with sets of shn or flac audio files and the make pro-
gram to automate the process of burning shn archive CD-R's, audio CD-
R's and the encoding of lossy mp3 and ogg-vorbis files.
shn and flac are lossless audio compression formats. shn and flac are
commonly used for distribution of high-quality live recordings of
"trade friendly" bands. You will find many via etree.org , or in USENET
groups like alt.binaries.gdead.
shn and flac file sets are typically distributed with a .nfo or .txt
file which contains the set list and other information.
Shn2make finds all the shn or flac files in the current directory and
checks thier md5 checksums. Then shn2make looks for the .nfo or .txt
file, and trys to figure out the song names and corresponding disc and
track numbers. The song names are matched against available shn/flac
files. Finally, if all the files check ok and everything is complete
and makes sense a Makefile is created.
Using this Makefile with the standard "make" utility, various tedious
sequences of tasks can be automatically performed on the set of shn or
flac files. For example archiving the set to CD, or encoding all the
songs to mp3 with the correct names.
EXAMPLE
Lets say you have downloaded a set of shns corresponding to two audio
CD's worth of free music. You have these files:
gd73-12-13.nfo
gd73-12-13d1t01.shn
gd73-12-13d1t02.shn
gd73-12-13d1t03.shn
gd73-12-13d1.md5
gd73-12-13d2t01.shn
gd73-12-13d2t02.shn
gd73-12-13d2.md5
With all this, the first thing is to run shn2make:
shn2make
After the GNU license notice, shn2make outputs:
Reading the contents of the nfo or .txt file...
Looking for shn or flac files in the current directory...
Matching songs listed in nfo to files...
Looking for songs in nfo file...
found md5 file : gd72-08-27.PB.md5
checking md5 for gd72-08-27d1t01.shn...OK
checking md5 for gd72-08-27d1t02.shn...OK
checking md5 for gd72-08-27d1t03.shn...OK
checking md5 for gd72-08-27d2t01.shn...OK
checking md5 for gd72-08-27d2t02.shn...OK
All checksums OK
"make shnarchive1" will archive disc(s) 1 2
Now you will have a Makefile.
To encode all the shn files to mp3:
make mp3
To archive the shn files to a CD-R (optimizing disk space, assuming
both audio discs worth of shns fit on a single CD-R):
make shnarchive1
When you create an archive disc, after the disk is recorded the cd is
mounted and the files written are re-verified.
If there is no nfo or txt file, shn2make will attempt to create one for
you and just use the file names.
If you are using shn2make as a backend to lmadl shn2make will use the
txt file generated by lmadl in preference to other txt files.
In the case of mulitple possible txt/nfo files to choose from,
shn2make simply try each of the files until it finds one that works.
If no txt/nfo files work, an error will be declared and processing
aborted.
To burn the the first disc in a set as an audio CD, put a blank in your
burner and:
make disc1
Once you have made the shn archive CD-R, you will want to share or
trade the music with your buds. Mount the shn archive disc (in your
standard, non-burning CD-ROM drive).
shn2make --srcdir /mnt/cd0 --partial
then make sure a blank is in the burner and
burn an audio CD-R to give away or play in your car.
make disc1
OPTIONS
--help -h
--version -v
show version identification
--dump -d
generate lots debugging information
--bitrate rate
default = variable bitrate encoding for lame, 192 for blade and
oggenc.
--quiet -q
do not print warnings or the banner to STDERR
--mp3encoder
--nonumbers -n
do not put side and track numbers into the ogg or wav file names
( 101_song.ogg becomes song.ogg ). The default is to use the
numbering scheme - so that things are played in the correct
order.
--srcdir dirpath
Use the directory specified instead of the default current
directory.
--ourdir dirpath
Use the directory specified for creation of lossy files
(mp3/ogg) instead of the current directory.
--tmpdir dirpath
Use the directory specified for doing the work (unpacking wavs,
builing iso's, etc.)
--cdpath path_to_cd-rom
Defines the mount path for the cd-rom.
--partial
Not a full set. Process anyway without for missing shn files.
--xmd5 -x
Bypass the md5 check on the shns.
--forcemd5
Force an md5 check on the shns.
--onlymd5
Perform md5 checks and then exit. No Makefile is generated.
--withoutimages -w
By default, any png, jpg, or gif files in the working directory
are added to the shn archives. These usually are scans of CD
covers or other things. Using this option suppresses this behav-
ior.
--makefilename
Sets the name of the created makefile. "Makefile" is the
default.
--overwrite
Do not ask about overwriting an existing makefile. Just do it.
--oggquality N
Set the quality for ogg encoding. Default is 6 ( very high)
--nonice
Suppress the use of nice for computationally intense operations.
--flac24
Tell shn2make that these flac files are flac24 and name the
archive sub-directory accordingly.
--indexedtracks -i
Shn files with names containing looking like "d1t102"
--keepfilenames
Instead of using the song names in the nfo file, just use the
file names as they are. For example the file gd85-06-14oade-
d2t10.flac will encode to an ogg file named gd85-06-14oade-
d2t10.ogg
RCFILE
You will need to add a file .shn2makerc to your home directory. This
has these entries:
CDPATH /media/cd0
Your burner mount point
CDR_DEVICE 1,0,0
Your burner device from cdrecord -scanbus
CDR_SPEED 12
The speed of your burner
CDR_SIZE 650
The capacity of a CD-ROM in MB.
TMP_DIR /usr2/tmp
A directory in which to do all processing. Needs at least
CDR_SIZE free space.
OGGQUALITY 5
The ogg quality setting to use for encoding. Default = 6.
DEPENDENCIES
shn2make requires:
perl 5 with the GetOpts::Long module (should be standard)
using shn2make requires:
shorten to uncompress shn files.
flac to uncompress flac files.
lame (or bladeenc) if you want to encode mp3 files.
oggenc if you want to encode encode ogg-vorbis files.
cdrecord to burn CDs.
md5sum to check checksums.
make to make it all work.
AVAILABLE TARGETS:
the Makefile generated by shn2make offers these main targets:
buildwav_dN
convert all the shns on disc N to wavs
buildmp3_dN
encode mp3's for all the shns on disc N
buildogg_dN
encode ogg's for all the shns on disc N
wavclean_dN
delete all the wav from disc N
mp3clean_dN
delete all the mp3's made from disc N
oggclean_dN
delete all the ogg's made from disc N
dummydiscN
(pretend to) burn an audio disc N ( cdrecord dummy mode)
discN burn an audio disc N
wav make wav's from all the shns on all discs
mp3 encode mp3's from all the shns on all discs
ogg encode ogg's from all the shns on all discs
wavclean
delete all wav files
mp3clean
delete all mp3 files
oggclean
delete all ogg files
isoX make an iso file of a shn archive X
shnarchiveX
burn shn archive X
flacarchiveX
burn flac archive X
copyisoX
make an duplicate iso from an already created archive disc.
copyarchiveX
burn a duplicate archive disc from an already created archive
disc.
isocleanX
delete the iso file for archive X
isoclean
delete all archive iso files.
BUGS and LIMITATIONS
shn2make has trouble with nfo files or file names which are unusually
formatted and vary greatly from etree standards. In particular nfo
files with un-numbered song names may cause trouble. shn files which do
not look like sometextdXtYY.shn where X is the disc number and YY is
the track number may cause trouble. Some variations of this are handled
correctly, but seemingly simple things, like shns with the actual song
names in the file name may not work. File names with blanks in them
also cause trouble. Currently shn2make handles about 95% of the posts
in alt.binaries.gdead and alt.binaries.gdead.highspeed and many
torrents.
YMMV.
If you have 1 flac file in the directory shn2make assumes flac for the
archive creation. If for some insane reason you had a mixed set of
flac and shn everything else should work.
FILES
~/.shn2makerc defines CD-ROM device and speed, temporary directory
location, and other installation specific options.
SEE ALSO
perl(1), lame(1), bladeenc(1), oggenc(1),
cdrecord(1),make(1),shorten(1),flac(1),md5sum(1)
LICENSE
shn2make is free software licensed under the GNU-GPL. See the file
COPYING for details.
AUTHOR
shn2make was written by Cliff Johnson who awaits your feedback and
ideas at
version 2.14 10 Oct 2005 shn2make(1)