3 ##############################################
4 # COMMAND LINE PROCESSING
6 # get the dvdtype from the command line
9 # remove the dvdtype from the args, and interpret the rest
10 # of the args to be passed directly to the rip_dvd script.
13 ##############################################
14 if [ -z "$dvdtype" ]; then
15 echo "-E- $0 <dvdtype>' is a required option"
19 ##############################################
20 # get the name of the DVD from the DVD disk
21 dvdname=`volname $dev | awk '{ print $1 }'`
22 dvdname=${dvdname%.} # remove trailing '.' character
24 ##############################################
25 # Find out what type of DVD we are ripping
26 # And set our destination directory appropriately
28 # - netflix = DVD ripped as an entire ISO image
29 # since these are only kept around until we watch them,
30 # there is no need to do anything less than full iso.
31 # - collection = Only DVD main feature is ripped
32 # - childrens = Only DVD main feature is ripped
33 # - church = Only DVD main feature is ripped
35 if [ "$dvdtype" == "netflix" ]; then
36 echo "-> Ripping Netflix DVD"
37 dest=/myth/video/DVDs/Netflix
39 elif [ "$dvdtype" == "collection" ]; then
40 echo "-> Ripping Personal Collection DVD"
41 dest=/myth/video/DVDs/Collection
43 elif [ "$dvdtype" == "childrens" ]; then
44 echo "-> Ripping Children's DVD"
45 dest=/myth/video/DVDs/Childrens
47 elif [ "$dvdtype" == "childrens" ]; then
48 echo "-> Ripping Church DVD"
49 dest=/myth/video/DVDs/Church
52 echo '-E- Must specify dvdtype as "netflix" or "collection" or "childrens" or "church"'
56 ##############################################
57 # Display progress window
59 # Pop up an xterm window and run the script inside of it
60 echo "xterm -T \"Ripping->$dvdname\" -geometry 72x15+20+10 -bg black -fg white -e \"/bin/bash\" -c \"$ripcmd -d $dest $rip_opts\" &"
61 xterm -T "Ripping->$dvdname" -geometry 72x15+20+10 -bg black -fg white -e "/bin/bash" -c "$ripcmd -d $dest $rip_opts" &
63 ##############################################
64 # OR display the script output directly in the terminal it's called from
65 #$ripcmd -d $dest $rip_opts
67 ##############################################