Skip to content

Instantly share code, notes, and snippets.

@jingoro
Created May 29, 2013 21:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jingoro/5673850 to your computer and use it in GitHub Desktop.
Save jingoro/5673850 to your computer and use it in GitHub Desktop.
#!/bin/bash
#
# Prerequisites: brew install mpg123 vorbis-tools
for fm in "$@"; do
f="${fm%.mp3}"
if [ "$f" != "$fm" ] && [ -a "$fm" ]; then
mpg123 -w - "$f.mp3" | oggenc -o "$f.ogg" -
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment