Search:

Matching Pages:

2013-05-07 WMA to MP3

This is based on How to Convert Unprotected WMA Files Into MP3 Files. I’m leaving the instructions here for my future self. 😊

for file in *.wma; do
mplayer -vo null -vc dummy -af resample=44100 \
-ao pcm:file="${file%%.[Ww][Mm][Aa]}.wav" "$file"
lame --preset standard "${file%%.[Ww][Mm][Aa]}.wav" \ "${file%%.[Ww][Mm][Aa]}.mp3"
done 

Use locate lame|grep 'lame$' and locate mplayer|grep 'mplayer$' to find the location of your executables. On a Mac, they’re probably not on your PATH… I installed MPlayer OSX and iTunes-LAME to get the executables. You’ll need to do something similar.

This is the result I just used for some files with upper case file extension:

for file in *.WMA; do
"/Applications/MPlayer OSX.app/Contents/Resources/External_Binaries/mplayer_intel.app/Contents/MacOS/mplayer" \
-vo null -vc dummy -af resample=44100 \
-ao pcm:file="${file%%.[Ww][Mm][Aa]}.wav" "$file"
"/Applications/iTunes-LAME.app/Contents/Resources/lame" \
--preset standard "${file%%.[Ww][Mm][Aa]}.wav" \ "${file%%.[Ww][Mm][Aa]}.mp3"
done 

Tags:

Once again, I’m syncing my wife’s iPhone 4S using iTunes and half way through the process it claims that it can’t do it because the computer is out of disk space. With more than 9 GB on the main hard disk and much more on the external hard disk (and a link from ~/Library/Application Support/MobilySync to the external hard disk), this is simply impossible. Strangely enough, synchronization continues anyway.