[linux-audio-user] lame and filenames
Christian Henz
chrhenz at gmx.de
Sat Sep 11 23:09:06 EDT 2004
On Sun, Sep 12, 2004 at 05:06:14AM +0400, Mikhail Ramendik wrote:
> Hello,
>
> I need to encode some WAV files into MP3. I'm planning to use Lame.
>
> Lame does not seem to accept wildcards, so I wrote a script-line:
>
> for a in *.wav; do lame --preset cbr 256 $a ; done
>
for a in *.wav; do lame $a `echo $a | sed 's/\(.*\)wav$/\1mp3/'`; done
This one should work as long as your *.wav file names don't contain spaces etc.
For reference, here is a mpp->ogg one-liner that handles those too:
ls -Q *.mpc | sed 's/\(.*\)\.mpc\(.*\)/\$HOME\/bin\/mppdec \1.mpc\2 - | oggenc -o \1.ogg\2 -/' | sh
cheers,
Christian
--
"Somewhere in Texas... a village is missing its idiot."
More information about the Linux-audio-user
mailing list