Skip to content

Instantly share code, notes, and snippets.

@jingle
Created February 24, 2013 09:41
Show Gist options
  • Save jingle/5023254 to your computer and use it in GitHub Desktop.
Save jingle/5023254 to your computer and use it in GitHub Desktop.
Convert ape to mp3 using avconv, split with mp3splt and cue
#!/bin/bash
find "$1" -type f -name "*.ape" -print0 | while read -d $'\0' song
do
output=${song%.ape}.mp3
cue=${song%.ape}.cue
avconv -i "$song" -b 192k "$output"
if ls "$cue" &> /dev/null; then
mp3splt -a -c "$cue" "$output"
rm "$output"
else
echo "no need to split"
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment