Split one flac (+ cue) file into separate tracks (update: including embedded cue files) 2009-02-09Posted by claudio in Uncategorized.
Tags: flac, GNU/Linux, music
You may have backupped your music cd’s using a single flac file instead of a file for each track. In case you need to split the cd-flac, do this:
Install the needed software:
$ sudo apt-get install cuetools shntool
Split the album flac file into separate tracks:
$ cuebreakpoints sample.cue | shnsplit -o flac sample.flac
Copy the flac tags (if present):
$ cuetag sample.cue split-track*.flac
The full howto can be found here (aidanjm).
Update (April 18th, 2009):
In case the cue file is not a separate file, but included in the flac file itself do this as the first step:
$ metaflac --show-tag=CUESHEET sample.flac | grep -v ^CUESHEET > sample.cue
(NB: The regular syntax is “metaflac –export-cuesheet-to=sample.cue sample.flac“, however often the cue file in embedded in a tag instead of the cuesheet block).