From 47433e5a60cd74da9d3abca82febfd4f84157619 Mon Sep 17 00:00:00 2001 From: Eric Hameleers Date: Thu, 24 Dec 2015 18:00:18 +0100 Subject: Stamp a VERSION number in the ISO, and to the USB partition. --- iso2usb.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'iso2usb.sh') diff --git a/iso2usb.sh b/iso2usb.sh index fe06678..d791c98 100644 --- a/iso2usb.sh +++ b/iso2usb.sh @@ -147,7 +147,7 @@ fi # Are all the required not-so-common add-on tools present? PROG_MISSING="" -for PROGN in blkid cpio extlinux fdisk gdisk mkdosfs sgdisk ; do +for PROGN in blkid cpio extlinux fdisk gdisk iso-info mkdosfs sgdisk ; do if ! PATH="/sbin:$PATH" which $PROGN 1>/dev/null 2>/dev/null ; then PROG_MISSING="${PROG_MISSING}-- $PROGN\n" fi @@ -267,6 +267,12 @@ cp ${EFIMNT}/EFI/BOOT/bootx64.efi ${USBMNT}/EFI/BOOT echo "--- Copying files from ISO to USB... takes some time." rsync -a ${RVERBOSE} ${ISOMNT}/* ${USBMNT}/ +# Write down the version of the ISO image: +VERSION=$(iso-info ${SLISO} |grep Application |cut -d: -f2- 2>/dev/null) +if [ -n "$VERSION" ]; then + echo "$VERSION" > ${USBMNT}/.isoversion +fi + # Create a temporary extraction directory for the initrd: mkdir -p /mnt IMGDIR=$(mktemp -d -p /mnt -t alienimg.XXXXXX) -- cgit v1.2.3