Convert Apple Lossless Audio file to MP3
Post ReplyConvert Apple Lossless Audio file to MP3Posted: Tuesday, June 25, 2013 [02:41:55] - 1
I needed a flash card for my car but car player does not play Apple Lossless Audio files. I've got 32Gb USB Flash drive and most of my music is in above named format. iTunes can convert them but it's a hassle. Wanted something "set and forget" sort of thing. Started with AppleScript and hit the wall - backslash escaping white space and other characters was a bummer. Forgot to mention - installed ffmpeg VIA MacPorts - turned-out to be the easiest way. To make a long story short - AppleScript: set the_folder to POSIX file p tell application "Finder" end tell and Perl file (I know, it's raw but it works): $files = <STDIN>; $files =~ s/ /\\ /g; $tofl = $files; $resf = `ls -la $files`; unless($resf =~ m/no such file/i) { print "Good\n"; `/opt/local/bin/ffmpeg -i $files -ar 44100 -ab 128 $tofl`; ## ACTUAL CONVERTER `rm $files`; } else {print "No file: $files\n";} Just run the AppleScript and have some coffee or tea, hell, you can have a beer if your library is big enough. |
RE: Convert Apple Lossless Audio file to MP3Posted: Tuesday, June 25, 2013 [03:06:42] - 2
Installing the ffmpeg with MacPorts is easy: just sit back and relax |