Backup DVD of television show to .mkv files

Alec Jacobson

March 03, 2013

weblog/

I bought some DVDs of a german tv show. With my fancy macbook air, I unfortunately have no way to play them: no DVD drive! So I dusted off my old laptop and installed vobcopy then I copied each dvd first to the old laptop from the disks using:
vobcopy -m
Then I copied these over to my macbook air. But these are just the raw dvd files (VIDEO_TS/*.VOB), which are rather large and unwieldy. To convert these to .mkv files I know to use Handbrake, but since I want to extract each of the 3 or 4 episodes per DVD, setting up Handbrake for each episode turned out to be too tedious. The presets in Handbrake don't include options to extract all audio channels and all subtitles by default. Instead I found a ruby script call hb.rb which can set up batch jobs. So finally to extract my episodes with all subtitles and all audio channels in tact I used:
./hb.rb --verbose --input ~/Downloads/IM_ANGESICHT_DES_VERBRECHENS_D2 --output "~/Downloads/#title#_#pos#.mkv" --min-length 00:10:00 --max-length 00:50:00 --skip-duplicates --audio-copy --skip-commentaries --only-first-track-per-language --autocrop