#!/bin/bash
#                      /usr/local/bin/copy_iso
# http://crystalfaeries.net/posix/bin/copy_iso
# Celeste Crystalfaery 2016-01-01 19:04:55+00:00
echo	"We are going to read an optical disk to hard disk, then burn a copy."
echo -n	"Enter name for saved .iso file (without blanks or extension), or null for temporary:"
read	 iso_name
if [	$iso_name == "" ]
then	# temporary
	file_name="`/usr/local/bin/now --tidy`"
else	# keep the .iso
	file_name="$iso_name"
fi
readom	dev=/dev/sr0	f=/.snapshots/hourly.0/usr/local/iso/"$file_name".iso
 wodim	-v -eject	  /.snapshots/hourly.0/usr/local/iso/"$file_name".iso
if [	$iso_name == "" ]
then	# temporary
	rm		  /.snapshots/hourly.0/usr/local/iso/"$file_name".iso	2>/dev/null
fi


syntax highlighted by Code2HTML, v. 0.9.1