Re: scripting lame in Linux

Robert Hegemann <[email protected]>
Newsgroups gmane.comp.audio.mp3.encoders
Message-ID <[email protected]>
Am Samstag, 10. November 2007 21:13 schrieb Marty:
> I have a lot of mp3 files that I want to re-compress with lame into smaller
> mp3s.  I want the input name to be the output name with _24 appended to it.
>  How could I use a script to do this in Linux?  This is the lame command:
>
> lame -m m -b 24 input.mp3 output_24.mp3

in one line:

for i in *.mp3 ; do o=$(basename "${i}" .mp3); lame -m m -b 
24 "$i" "${o}_24.mp3"; done



or in multiple lines

for i in *.mp3
do
  o=$(basename "${i}" .mp3)
  lame -m m -b 24 "$i" "${o}_24.mp3"
done

> Marty



Ciao Robert

PS: I'm using the bash shell
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.