From: <smi...@us...> - 2004-02-14 16:44:26
|
Update of /cvsroot/devil-linux/build/config/etc/initrd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11414/config/etc/initrd Modified Files: linuxrc mount_cdrom Log Message: first basic support for remote upgrade of DL on writeable device (i.e. USB stick) Index: linuxrc =================================================================== RCS file: /cvsroot/devil-linux/build/config/etc/initrd/linuxrc,v retrieving revision 1.59 retrieving revision 1.60 diff -u -d -r1.59 -r1.60 --- linuxrc 1 Feb 2004 15:51:41 -0000 1.59 +++ linuxrc 14 Feb 2004 16:37:52 -0000 1.60 @@ -17,6 +17,7 @@ GREEN="echo -en \\033[1;32m" YELLOW="echo -en \\033[1;33m" RED="echo -en \\033[1;31m" +BLUE="echo -en \\033[1;34m" alias beep='echo -en "\007"' alias l="ls -la" Index: mount_cdrom =================================================================== RCS file: /cvsroot/devil-linux/build/config/etc/initrd/mount_cdrom,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- mount_cdrom 9 Nov 2003 17:38:14 -0000 1.20 +++ mount_cdrom 14 Feb 2004 16:37:52 -0000 1.21 @@ -12,6 +12,7 @@ GREEN="echo -en \\033[1;32m" YELLOW="echo -en \\033[1;33m" RED="echo -en \\033[1;31m" +BLUE="echo -en \\033[1;34m" alias beep='echo -en "\007"' if [ "$3" != "silent" ]; then @@ -51,6 +52,30 @@ echo checking $disk if mount -n -t auto -o rw,noatime $disk /mnt 2> /dev/null; then if [ -e /mnt/DEVIL-LINUX ] ; then + if [ -e /mnt/bootcd.iso.new ] ; then + $BLUE + echo "****************************" + echo "* Found Devil-Linux update *" + echo "****************************" + echo + echo "Backing up old version" + $RED + rm -f /mnt/bootcd.iso.old &> /dev/null + mv /mnt/bootcd.iso /mnt/bootcd.iso.old || echo "Backup failed" + $BLUE + echo "Activating new version" + $RED + rm -f /mnt/bootcd.iso &> /dev/null + if mv /mnt/bootcd.iso.new /mnt/bootcd.iso ; then + # create flag file, so the other scripts know about it + touch /shm/dl_iso_replaced + else + echo "Activation failed" + fi + # make sure the changes are written immediately + sync + $NORMAL + fi if [ -e /mnt/bootcd.iso ] ; then mount -o loop -t iso9660 /mnt/bootcd.iso $1 || return 1 exit 0 |