diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2012-12-31 05:04:42 +0400 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2012-12-31 05:04:42 +0400 |
commit | 71dc8760ff4de5f365330d1bc571d934deb54af9 (patch) | |
tree | 7346d42a282562a3937d82307012b5857d642ce6 /icedax/readmult | |
download | cdrkit-upstream.tar.gz |
Imported Upstream version 1.1.11upstream/1.1.11upstream
Diffstat (limited to 'icedax/readmult')
-rwxr-xr-x | icedax/readmult | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/icedax/readmult b/icedax/readmult new file mode 100755 index 0000000..6f0884e --- /dev/null +++ b/icedax/readmult @@ -0,0 +1,31 @@ +#! /bin/sh +# +# Script to read more than 1 song with icedax +# Each file gets an individual name from the command line +# +# based on a perl script from Matthias Schniedermeyer +# +# usage: readmult <track a> <title a> <track b> <title b> ... +# +# example: readmult 1 intro 3 lovesong 5 medley +# will produce a file named intro.wav for track 1, +# a file named lovesong.wav for track 3, and +# a file named medley.wav for track 5. +# +CDDA2WAV=icedax +CDDA2WAVOPTS="-P0" + +if [ $(( $# % 2 )) -eq 0 ]; then + while [ $# -ge 2 ]; do + $CDDA2WAV $CDDA2WAVOPTS -Owav -t $1 $PREFIX$2".wav" + RES=$? + if [ $RES -ne 0 ]; then + echo "$CDDA2WAV error, return value "$RES". Aborted." >&2 + break + fi + shift 2 + done +else + echo "usage: $0 [<Tracknr> <Filename>] ..." >&2 +fi + |