-
-
Save muhaha03/db6f0a7eba4702195ed0848500e63396 to your computer and use it in GitHub Desktop.
Split .ape and .flac and convert to .m4a (ALAC) or .mp3 on MacOS X
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
brew install flac ffmpeg cuetools # ставим нужные пакеты | |
# скачиваем cuetag.sh скрипт, например отсюда https://github.com/gumayunov/split-cue/blob/master/cuetag | |
ffmpeg -i 1.ape 1.flac # конвертируем во flac, так как libmac для APE не ставится на osx | |
cuebreakpoints 1.cue | shnsplit -o flac 1.flac #нарезаем на треки | |
cuetag 1.cue split-track*.flac #прописываем тэги (cuetag.sh ставится отдельно отдельно) | |
#конвертируем в ALAC | |
for f in split-track*.flac | |
do | |
ffmpeg -i "$f" -acodec alac "${f%.flac}.m4a"; | |
done | |
#если надо то MP3, то конвертируем так | |
for f in split-track*.flac | |
do | |
ffmpeg -i $f -ab 320k -ac 2 -ar 48000 ${f%.*}.mp3 | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment