# Rip audio using cdparanoia cdparanoia -v -- "1-" data.wav # Rip toc using cdrdao cdrdao read-toc data.toc # Pull in CDDB info (if it exists; otherwise, you'll have to do this manually) cdrdao read-cddb data.toc # Convert toc to cue cuetools data.toc data.cue # Encode to FLAC flac --replay-gain --cuesheet=data.cue --best data.wav # Encode to MP3 lame --preset extreme --replaygain-accurate --clipdetect -p data.wav data.mp3