#!/bin/sh # burn-dvd # count_zero 2006 # Burns DVD-compliant video # # Usage: # 1) burn-dvd # 2) burn-dvd # 3) burn-dvd device='/dev/dvd' movie=$1 title=`echo $movie | sed 's/\.[a-zA-Z0-9]*$//'` type=`echo $movie | grep [.].* | sed 's/.*\.//'` if [[ -n `echo $type` ]] then if [[ `echo $type` = 'mpg' ]] then if [[ -e "$movie.xml" ]] then : else echo " " > "$title.xml" fi dvdauthor -o 'DVD' -x "$title.xml" elif [[ `echo $type` = 'iso' ]] then growisofs -Z $device=$movie exit 0 else echo 'Video Stream is not an mpg file' fi else growisofs -dvd-video -udf -Z $device $movie fi