Updating copyright header in live-snapshot.
[live-boot-grml.git] / bin / live-snapshot
index b5a7fa4..dc1fa6d 100755 (executable)
@@ -2,11 +2,11 @@
 
 # live-snapshot - utility to manage Debian Live systems snapshots
 #
-#   This program mount a device (fallback to /tmpfs under $MOUNTP
-#   and save the /live/cow (or a different dir) filesystem in it for reusing
+#   This program mounts a device (fallback to /tmpfs under $MOUNTP
+#   and saves the /live/cow (or a different dir) filesystem in it for reuse
 #   in another live-initramfs session. Look at manpage for more info.
 #
-# Copyright (C) 2006 Marco Amadori <marco.amadori@gmail.com>
+# Copyright (C) 2006-2008 Marco Amadori <marco.amadori@gmail.com>
 # Copyright (C) 2008 Chris Lamb <chris@chris-lamb.co.uk>
 #
 # This program is free software; you can redistribute it and/or modify
@@ -34,7 +34,6 @@ set -eu
 export USERNAME USERFULLNAME HOSTNAME
 
 PROGRAM="$(basename $0)"
-VERSION=0.0.2
 
 # Needs to be available at run and reboot time
 SAFE_TMPDIR="/live"
@@ -96,13 +95,13 @@ Usage ()
 
        exit 0
 }
-       
 
 Version ()
 {
-       echo "${PROGRAM}, version ${VERSION}"
+       echo "${PROGRAM}"
        echo
        echo "Copyright (C) 2006 Marco Amadori <marco.amadori@gmail.com>"
+       echo "Copyright (C) 2008 Chris Lamb <chris@chris-lamb.co.uk>"
        echo
        echo "This program is free software; you can redistribute it and/or modify"
        echo "it under the terms of the GNU General Public License as published by"
@@ -198,7 +197,6 @@ Parse_args ()
 
                esac
        done
-
 }
 
 Defaults ()
@@ -230,7 +228,6 @@ Defaults ()
                                Error "unrecognized resync string"
                                ;;
                esac
-
        else
                # Set target file based on image
                case "${SNAP_TYPE}" in
@@ -247,14 +244,14 @@ Defaults ()
                                ;;
                esac
        fi
-
 }
 
 Validate_input ()
 {
-       case "${SNAP_TYPE}" in 
+       case "${SNAP_TYPE}" in
                cpio|squashfs|jffs2|ext2|ext3)
                        ;;
+
                *)
                        Error "invalid filesystem type \"${SNAP_TYPE}\""
                        ;;
@@ -280,6 +277,7 @@ Mount_device ()
                        # create a temp
                        mount -t tmpfs -o rw tmpfs "${MOUNTP}"
                        ;;
+
                *)
                        if [ -b "${SNAP_DEV}" ]
                        then
@@ -334,7 +332,7 @@ Main ()
        Parse_args "${@}"
        Defaults
        Validate_input
-       trap 'Clean' EXIT 
+       trap 'Clean' EXIT
        Mount_device
        Do_snapshot
 }