# HG changeset patch # User Robert McIntyre # Date 1369363921 14400 # Node ID e2bef5c2dc286c2aec764a88ba5e6ce899199e8b # Parent 413c2abaaf765c8cb9dbd6241b0668f912aad14e move cruft. diff -r 413c2abaaf76 -r e2bef5c2dc28 backup-home --- a/backup-home Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,7 +0,0 @@ -#!/bin/sh - -tar -vcpjf /backups/home-$(date +"%F-%H:%M").tar.bz2 \ ---one-file-system \ --C /home \ ---exclude=./lost+found \ -. diff -r 413c2abaaf76 -r e2bef5c2dc28 backup-system --- a/backup-system Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,13 +0,0 @@ -#!/bin/sh - -tar -vcpjf /backups/system-$(date +"%F-%H:%M").tar.bz2 \ ---one-file-system \ ---exclude=/proc/* \ ---exclude=/sys/* \ ---exclude=/dev/* \ ---exclude=/tmp/* \ ---exclude=/lost+found \ ---exclude=/boot/lost+found \ ---exclude=/root/* \ ---exclude=/kernel/* \ --C / /boot / diff -r 413c2abaaf76 -r e2bef5c2dc28 burn-tmp-iso-image.sh --- a/burn-tmp-iso-image.sh Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,7 +0,0 @@ -#!/bin/sh - -TARGET=/home/r/tmp/image.iso - -cdrecord -multi -v gracetime=3 -overburn -data "$TARGET" - -#rm $TARGET diff -r 413c2abaaf76 -r e2bef5c2dc28 cd-backup-parse.pl --- a/cd-backup-parse.pl Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,89 +0,0 @@ -#!/bin/perl - -$tmp_iso="/home/r/tmp/image.iso"; - - -use File::Basename; - -$session_info = `cdrecord -minfo 2>/dev/null`; -$multi_sessionP = false; - - -# get the last 2 lines from $session_info, and use them to construct -# the proper flags for mkisofs. - -@session_info_lines = split("\n", $session_info); - -$session_number_line = $session_info_lines[-2]; -$start_address_line = $session_info_lines[-1]; - -if ($session_number_line =~ m/^Last session start address:\s*(\d+)/){ - $session_number = $1; - if ($start_address_line =~ m/^Last session leadout start address:\s*(\d+)/){ - $start_address = $1; - $multi_sessionP = true; - } -} - -#print "$multi_sessionP\n$session_number\n$start_address\n"; - -@graft_points = ("-graft-points"); - -for $graft_point(@ARGV){ - push(@graft_points, basename($graft_point) . "=" . $graft_point); -} - -@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); - - -if ($multi_sessionP){ - $C_spec = "$session_number,$start_address"; - @additional_args = ("-M", "/dev/cdrom", "-C", $C_spec); - @create_iso_command = (@create_iso_command, @additional_args); -} - -@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); - - -@remove_previous_iso_command = ("rm", "-f", $tmp_iso); -print "@remove_previous_iso_command\n"; -system(@remove_previous_iso_command); - -print "@create_iso_command\n"; -system(@create_iso_command); - -print "Created $tmp_iso.\n"; -print "Use burn-tmp-iso-image to write to CD.\n"; -if ($multi_sessionP){ - print "Note: this will be a multisession disk!.\n" -} - -# #START=`cdrecord -msinfo` - -# #echo "$START" - -# GRAFT_POINTS='' - -# for var in "$@" -# do -# GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" -# done - - -# #echo $GRAFT_POINTS - -# #if [ "$START" == "0,0" ]; then -# COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" -# # echo $COMMAND -# # eval $COMMAND -# #else -# # COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ -# # -C $START -o $TARGET -graft-points $GRAFT_POINTS" -# echo $COMMAND -# eval $COMMAND -# #fi - - -# echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." - -# #cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 cd-backup.pl --- a/cd-backup.pl Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,90 +0,0 @@ -#!/bin/perl - -$tmp_iso="/home/r/tmp/image.iso"; - - -use File::Basename; - -$session_info = `cdrecord -minfo 2>/dev/null`; -$multi_sessionP = false; - - -# get the last 2 lines from $session_info, and use them to construct -# the proper flags for mkisofs. - -@session_info_lines = split("\n", $session_info); - -$session_number_line = $session_info_lines[-2]; -$start_address_line = $session_info_lines[-1]; - -if ($session_number_line =~ m/^Last session start address:\s*(\d+)/){ - $session_number = $1; - if ($start_address_line =~ m/^Last session leadout start address:\s*(\d+)/){ - $start_address = $1; - $multi_sessionP = true; - } -} - -#print "$multi_sessionP\n$session_number\n$start_address\n"; - -@graft_points = ("-graft-points"); - -for $graft_point(@ARGV){ - push(@graft_points, basename($graft_point) . "=" . $graft_point); -} - -@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); - - -if ($multi_sessionP){ -# $C_spec = "$session_number,$start_address"; - $C_spec = "1,$start_address"; - @additional_args = ("-M", "/dev/cdrom", "-C", $C_spec); - @create_iso_command = (@create_iso_command, @additional_args); -} - -@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); - - -@remove_previous_iso_command = ("rm", "-f", $tmp_iso); -print "@remove_previous_iso_command\n"; -system(@remove_previous_iso_command); - -print "@create_iso_command\n"; -system(@create_iso_command); - -print "Created $tmp_iso.\n"; -print "Use burn-tmp-iso-image to write to CD.\n"; -if ($multi_sessionP){ - print "Note: this will be a multisession disk!.\n" -} - -# #START=`cdrecord -msinfo` - -# #echo "$START" - -# GRAFT_POINTS='' - -# for var in "$@" -# do -# GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" -# done - - -# #echo $GRAFT_POINTS - -# #if [ "$START" == "0,0" ]; then -# COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" -# # echo $COMMAND -# # eval $COMMAND -# #else -# # COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ -# # -C $START -o $TARGET -graft-points $GRAFT_POINTS" -# echo $COMMAND -# eval $COMMAND -# #fi - - -# echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." - -# #cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 cd-backup.sh --- a/cd-backup.sh Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -#!/bin/sh - -TARGET="/home/r/tmp/image.iso" - -#START=`cdrecord -msinfo` - -#echo "$START" - -GRAFT_POINTS='' - -for var in "$@" -do - GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" -done - - -#echo $GRAFT_POINTS - -#if [ "$START" == "0,0" ]; then - COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" -# echo $COMMAND -# eval $COMMAND -#else -# COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ -# -C $START -o $TARGET -graft-points $GRAFT_POINTS" - echo $COMMAND -# eval $COMMAND -#fi - - -echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." - -#cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/backup-home --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/backup-home Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,7 @@ +#!/bin/sh + +tar -vcpjf /backups/home-$(date +"%F-%H:%M").tar.bz2 \ +--one-file-system \ +-C /home \ +--exclude=./lost+found \ +. diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/backup-system --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/backup-system Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,13 @@ +#!/bin/sh + +tar -vcpjf /backups/system-$(date +"%F-%H:%M").tar.bz2 \ +--one-file-system \ +--exclude=/proc/* \ +--exclude=/sys/* \ +--exclude=/dev/* \ +--exclude=/tmp/* \ +--exclude=/lost+found \ +--exclude=/boot/lost+found \ +--exclude=/root/* \ +--exclude=/kernel/* \ +-C / /boot / diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/burn-tmp-iso-image.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/burn-tmp-iso-image.sh Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,7 @@ +#!/bin/sh + +TARGET=/home/r/tmp/image.iso + +cdrecord -multi -v gracetime=3 -overburn -data "$TARGET" + +#rm $TARGET diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/cd-backup-parse.pl --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/cd-backup-parse.pl Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,89 @@ +#!/bin/perl + +$tmp_iso="/home/r/tmp/image.iso"; + + +use File::Basename; + +$session_info = `cdrecord -minfo 2>/dev/null`; +$multi_sessionP = false; + + +# get the last 2 lines from $session_info, and use them to construct +# the proper flags for mkisofs. + +@session_info_lines = split("\n", $session_info); + +$session_number_line = $session_info_lines[-2]; +$start_address_line = $session_info_lines[-1]; + +if ($session_number_line =~ m/^Last session start address:\s*(\d+)/){ + $session_number = $1; + if ($start_address_line =~ m/^Last session leadout start address:\s*(\d+)/){ + $start_address = $1; + $multi_sessionP = true; + } +} + +#print "$multi_sessionP\n$session_number\n$start_address\n"; + +@graft_points = ("-graft-points"); + +for $graft_point(@ARGV){ + push(@graft_points, basename($graft_point) . "=" . $graft_point); +} + +@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); + + +if ($multi_sessionP){ + $C_spec = "$session_number,$start_address"; + @additional_args = ("-M", "/dev/cdrom", "-C", $C_spec); + @create_iso_command = (@create_iso_command, @additional_args); +} + +@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); + + +@remove_previous_iso_command = ("rm", "-f", $tmp_iso); +print "@remove_previous_iso_command\n"; +system(@remove_previous_iso_command); + +print "@create_iso_command\n"; +system(@create_iso_command); + +print "Created $tmp_iso.\n"; +print "Use burn-tmp-iso-image to write to CD.\n"; +if ($multi_sessionP){ + print "Note: this will be a multisession disk!.\n" +} + +# #START=`cdrecord -msinfo` + +# #echo "$START" + +# GRAFT_POINTS='' + +# for var in "$@" +# do +# GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" +# done + + +# #echo $GRAFT_POINTS + +# #if [ "$START" == "0,0" ]; then +# COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" +# # echo $COMMAND +# # eval $COMMAND +# #else +# # COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ +# # -C $START -o $TARGET -graft-points $GRAFT_POINTS" +# echo $COMMAND +# eval $COMMAND +# #fi + + +# echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." + +# #cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/cd-backup.pl --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/cd-backup.pl Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,90 @@ +#!/bin/perl + +$tmp_iso="/home/r/tmp/image.iso"; + + +use File::Basename; + +$session_info = `cdrecord -minfo 2>/dev/null`; +$multi_sessionP = false; + + +# get the last 2 lines from $session_info, and use them to construct +# the proper flags for mkisofs. + +@session_info_lines = split("\n", $session_info); + +$session_number_line = $session_info_lines[-2]; +$start_address_line = $session_info_lines[-1]; + +if ($session_number_line =~ m/^Last session start address:\s*(\d+)/){ + $session_number = $1; + if ($start_address_line =~ m/^Last session leadout start address:\s*(\d+)/){ + $start_address = $1; + $multi_sessionP = true; + } +} + +#print "$multi_sessionP\n$session_number\n$start_address\n"; + +@graft_points = ("-graft-points"); + +for $graft_point(@ARGV){ + push(@graft_points, basename($graft_point) . "=" . $graft_point); +} + +@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); + + +if ($multi_sessionP){ +# $C_spec = "$session_number,$start_address"; + $C_spec = "1,$start_address"; + @additional_args = ("-M", "/dev/cdrom", "-C", $C_spec); + @create_iso_command = (@create_iso_command, @additional_args); +} + +@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); + + +@remove_previous_iso_command = ("rm", "-f", $tmp_iso); +print "@remove_previous_iso_command\n"; +system(@remove_previous_iso_command); + +print "@create_iso_command\n"; +system(@create_iso_command); + +print "Created $tmp_iso.\n"; +print "Use burn-tmp-iso-image to write to CD.\n"; +if ($multi_sessionP){ + print "Note: this will be a multisession disk!.\n" +} + +# #START=`cdrecord -msinfo` + +# #echo "$START" + +# GRAFT_POINTS='' + +# for var in "$@" +# do +# GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" +# done + + +# #echo $GRAFT_POINTS + +# #if [ "$START" == "0,0" ]; then +# COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" +# # echo $COMMAND +# # eval $COMMAND +# #else +# # COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ +# # -C $START -o $TARGET -graft-points $GRAFT_POINTS" +# echo $COMMAND +# eval $COMMAND +# #fi + + +# echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." + +# #cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/cd-backup.sh --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/cd-backup.sh Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,33 @@ +#!/bin/sh + +TARGET="/home/r/tmp/image.iso" + +#START=`cdrecord -msinfo` + +#echo "$START" + +GRAFT_POINTS='' + +for var in "$@" +do + GRAFT_POINTS="$GRAFT_POINTS \"`basename "$var"`\"=\"$var\"" +done + + +#echo $GRAFT_POINTS + +#if [ "$START" == "0,0" ]; then + COMMAND="mkisofs -iso-level 4 -rJT -o $TARGET -graft-points $GRAFT_POINTS" +# echo $COMMAND +# eval $COMMAND +#else +# COMMAND="mkisofs -iso-level 4 -rJT -M /dev/cdrom \ +# -C $START -o $TARGET -graft-points $GRAFT_POINTS" + echo $COMMAND +# eval $COMMAND +#fi + + +echo "files copied to $TARGET. use 'burn-tmp-iso-image' to burn it." + +#cd-burn diff -r 413c2abaaf76 -r e2bef5c2dc28 crvft/simple-cd-backup.pl --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/crvft/simple-cd-backup.pl Thu May 23 22:52:01 2013 -0400 @@ -0,0 +1,23 @@ +#!/bin/perl +use File::Basename; + +@graft_points = ("-graft-points"); + +for $graft_point(@ARGV){ + push(@graft_points, basename($graft_point) . "=" . $graft_point); +} + +@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); + +@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); + + +@remove_previous_iso_command = ("rm", "-f", $tmp_iso); +print "@remove_previous_iso_command\n"; +system(@remove_previous_iso_command); + +print "@create_iso_command\n"; +system(@create_iso_command); + +print "Created $tmp_iso.\n"; +print "Use burn-tmp-iso-image to write to CD.\n"; diff -r 413c2abaaf76 -r e2bef5c2dc28 simple-cd-backup.pl --- a/simple-cd-backup.pl Sun May 19 14:56:11 2013 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,23 +0,0 @@ -#!/bin/perl -use File::Basename; - -@graft_points = ("-graft-points"); - -for $graft_point(@ARGV){ - push(@graft_points, basename($graft_point) . "=" . $graft_point); -} - -@create_iso_command = ("mkisofs", "-iso-level", "4", "-r", "-J", "-T"); - -@create_iso_command = (@create_iso_command, "-o", $tmp_iso, @graft_points); - - -@remove_previous_iso_command = ("rm", "-f", $tmp_iso); -print "@remove_previous_iso_command\n"; -system(@remove_previous_iso_command); - -print "@create_iso_command\n"; -system(@create_iso_command); - -print "Created $tmp_iso.\n"; -print "Use burn-tmp-iso-image to write to CD.\n";