Created
November 22, 2011 13:16
-
-
Save rriemann/1385642 to your computer and use it in GitHub Desktop.
Convert all audio/video files recursively to another format
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# inspired by: http://yogsototh.wordpress.com/2007/10/24/bash-script-loop/ | |
# this probably only works within the zsh. So you might enter it first by execute 'zsh' | |
# also works with whitespaces in filenames | |
for file in ./**/*.wma; do | |
ffmpeg -i $file -f ogg -acodec libvorbis -ab 128k ${file%.*}.ogg | |
mkdir -p ./old_wma/${file%/*} | |
mv $file ./old_wma/${file} | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment