# TinyCore Grub Config set isopath_tinycore="${isopath}/tinycore" export isopath_tinycore # abuse for to check for existence for isofile in $isopath_tinycore/*.iso; do if [ ! -e "$isofile" ]; then break; fi submenu "TinyCore Linux >" --class tinycore { for isofile in ${isopath_tinycore}/*Core*.iso; do if [ ! -e "$isofile" ]; then break; fi regexp \ --set 1:isoname \ --set 2:variant \ --set 3:version \ "^${isopath_tinycore}/((.*Core[^-]*)-(.+)\.iso)\$" "${isofile}" menuentry "${variant} ${version}" "${isofile}" "${isoname}" --class tinycore { set isofile=$2 set isoname=$3 echo "Using ${isoname}..." loopback loop $isofile # ideas to add for CorePlus: loglevel=3 cde showapps desktop=flwm_topside linux (loop)/boot/vmlinuz initrd (loop)/boot/core.gz } done } # kill for loop break done