diff options
author | Micah Anderson <micah@riseup.net> | 2010-01-17 23:54:09 +1300 |
---|---|---|
committer | Micah Anderson <micah@riseup.net> | 2010-01-17 23:54:09 +1300 |
commit | fe3620c6529cc449cd152ed58667e39d4a80257e (patch) | |
tree | ec83be42237855979a31f38cdce51f45cdbd7312 /handlers/makecd.in | |
parent | 18f28c2cb00286cc0ff790ef6b6914f3f22ec4ac (diff) | |
parent | 46eccf2fd0c894790405b2e3aae8dfb99f5a5d98 (diff) | |
download | backupninja-fe3620c6529cc449cd152ed58667e39d4a80257e.tar.gz backupninja-fe3620c6529cc449cd152ed58667e39d4a80257e.tar.bz2 |
Merge branch 'master' into debian
Conflicts:
AUTHORS
ChangeLog
handlers/maildir.in
handlers/mysql.in
handlers/rsync.in
handlers/sys.helper.in
handlers/sys.in
src/backupninja.in
Diffstat (limited to 'handlers/makecd.in')
-rw-r--r-- | handlers/makecd.in | 61 |
1 files changed, 31 insertions, 30 deletions
diff --git a/handlers/makecd.in b/handlers/makecd.in index 1a95d6d..d44bba3 100644 --- a/handlers/makecd.in +++ b/handlers/makecd.in @@ -1,4 +1,5 @@ # -*- mode: sh; sh-basic-offset: 3; indent-tabs-mode: nil; -*- +# vim: set filetype=sh sw=3 sts=3 expandtab autoindent: # # burncd handler script for backupninja # @@ -31,7 +32,7 @@ DVDINFO="/usr/bin/dvd+rw-mediainfo" [ -x "$CDRDAO" ] || debug 3 "echo executable $CDRDAO not present" if [ "$isoonly" == "no" ]; then - [ -e $device ] || fatal "No Burner device available" + [ -e $device ] || fatal "No Burner device available" fi outputfile="$backupdir/$imagefile" @@ -40,7 +41,7 @@ execstr="nice -n $nicelevel $MKISOFS --quiet -R -o $outputfile " str="" # excludes for i in $exclude; do - str=" -x ${i}$str" + str=" -x ${i}$str" done debug 0 "echo $str " @@ -50,39 +51,39 @@ debug 0 "echo $execstr " output=` $execstr 2>&1 ` code=$? if [ "$code" == "0" ]; then - debug $output - info "Successfully finished creation of iso" + debug $output + info "Successfully finished creation of iso" else - warning $output - warning "Failed to create iso" + warning $output + warning "Failed to create iso" fi if [ "$isoonly" == "no" ]; then - if [ "$burnertype" == "cd" ]; then - # burning iso to CD - $CDRECORD -v gracetime=2 dev=$device speed=8 -dao -data $outputfile - code=$? - if [ "$code" == "0" ]; then - debug $output - info "Successfully burned CD" - else - warning $output - warning "Failed to create CD" - fi - fi - if [ "$burnertype" == "dvd" ]; then - # burning iso dvd - $GROWISOFS -speed=2 -Z $device=$outputfile -use-the-force-luke=notray -use-the-force-luke=tty - code=$? - if [ "$code" == "0" ]; then - debug $output - info "Successfully burned DVD" - else - warning $output - warning "Failed to create DVD" - fi - fi + if [ "$burnertype" == "cd" ]; then + # burning iso to CD + $CDRECORD -v gracetime=2 dev=$device speed=8 -dao -data $outputfile + code=$? + if [ "$code" == "0" ]; then + debug $output + info "Successfully burned CD" + else + warning $output + warning "Failed to create CD" + fi + fi + if [ "$burnertype" == "dvd" ]; then + # burning iso dvd + $GROWISOFS -speed=2 -Z $device=$outputfile -use-the-force-luke=notray -use-the-force-luke=tty + code=$? + if [ "$code" == "0" ]; then + debug $output + info "Successfully burned DVD" + else + warning $output + warning "Failed to create DVD" + fi + fi fi return 0 |