lyncd

Posts tagged ‘flac’

One-liner to recursively convert flac to mp3

Here’s what I do, it uses FFmpeg, doesn’t require a for loop and should work on any POSIX-compliant system. Take note that it will delete your original files! The idea is to make a copy of your music folder first, and then run this command on the copy.

find -name "*.flac" -exec sh -c 'ffmpeg -i "$1" -acodec libmp3lame -aq 4 "${1%.flac}.mp3" && rm -f "$1"' _ {} \;

And that’s it! more …

Filed under: Code.  Tagged: , , , .