Re: [LAD] [LAU] mp3tom4a via find and ffmpeg

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: guerrier <guerrier@...>
Cc: <linux-audio-user@...>, <linux-audio-dev@...>
Date: Friday, August 12, 2011 - 5:26 pm

Hello Guerrier!
Well that could end up being a little massy. Depending on spaces in
filenames. You might try something like:
for F in `find ./ -name "*.mp3"`; do
ffmpeg -i "$F" -y -acodec libfaac -ab 192k "$F".m4a;
done

You could use mmv later on to move the .mp3.m4a files or you can use some
shell magic, I've just seen this recently, I think it worked with percent
signs, but I can't remember the sybntax. If you know about sed or awk, you
could do something like:
O=`echo "$F" | sed -e "+s/\.mp3$/.m4a/g"`
Then your output filename will be $O in the script. I think this is better
than the awk idea. :-)
Warm regards
Julien
=-=-=-=-=-=-=-=-=-=-=-=-
Such Is Life: Very Intensely Adorable;
Frightening Absence Just Arriving, Reigns Disappeared, Ornate - flowers!

====== Find my music at ======
http://juliencoder.de/nama/music.html
.....................................
"If you live to be 100, I hope I live to be 100 minus 1 day,
so I never have to live without you." (Winnie the Pooh)
_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@lists.linuxaudio.org
http://lists.linuxaudio.org/listinfo/linux-audio-dev

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[LAD] mp3tom4a via find and ffmpeg, guerrier, (Fri Aug 12, 5:11 pm)
Re: [LAD] [LAU] mp3tom4a via find and ffmpeg, Julien Claassen, (Fri Aug 12, 5:26 pm)
Re: [LAD] mp3tom4a via find and ffmpeg, karthik poduval, (Fri Aug 12, 5:20 pm)
Re: [LAD] mp3tom4a via find and ffmpeg, Julien Claassen, (Fri Aug 12, 5:28 pm)
Re: [LAD] mp3tom4a via find and ffmpeg, Paul Giblock, (Fri Aug 12, 5:19 pm)