shnsplit
Split audio files using CUE sheets
TLDR
SYNOPSIS
shnsplit [OPTIONS] [file]shntool split [OPTIONS] [file]
DESCRIPTION
shnsplit splits a single large audio file into multiple individual track files using split points defined in a CUE sheet. It is part of the shntool suite and supports various lossless audio formats including WAV, FLAC, APE, and Shorten.Split points can be specified in several formats: bytes, m:ss (minutes:seconds), m:ss.ff (CD frames, 75 per second), or m:ss.nnn (milliseconds). The tool is commonly used to split CD rips, live recordings, or continuous mixes into individual tracks.
PARAMETERS
-f file
Read split points from CUE sheet or split point file-o format
Output format (wav, flac, ape, shn, wv)-d dirname
Output directory for split files-t fmt
Name files using CUE fields (%n=track, %a=album, %t=title, %p=performer)-a str
Prefix output filenames with str (default: split-track)-z str
Postfix output filenames with str-c num
Start counting from num when naming output files (default: 0)-l len
Split input file into segments of length len-m str
Character manipulation string for filenames from CUE sheets (alternating from/to pairs)-n fmt
Specify file count output format (default: %02d)-x list
Extract specific tracks only (e.g., "2-6,9,11-13")-e len
Add lead-in from previous track-u len
Add lead-out from next track-i fmt
Specify input file format decoder and/or arguments-O val
Overwrite existing files: ask, always, or never-q
Suppress non-critical output (quiet mode)-w
Suppress warnings-D
Print debugging information-h
Display help information
CAVEATS
Requires appropriate encoders/decoders (flac, wavpack, mac) installed for non-WAV formats. Split accuracy depends entirely on CUE sheet correctness. Does not transfer metadata to output files; use cuetag.sh for tagging after splitting. Output files are created in current directory unless -d specifies otherwise.
HISTORY
shntool and shnsplit were developed by Jason Jordan as part of the shntool audio processing suite. The project began in the early 2000s to provide Unix/Linux users with tools for handling Shorten (.shn) files, which were popular for lossless audio distribution. The suite expanded to support multiple formats and remains a standard tool for audio file manipulation.
SEE ALSO
cuebreakpoints(1), cuetag(1), flac(1), sox(1), ffmpeg(1)
