for isofile in $isopath/openSUSE-Tumbleweed-*-Live-*.iso; do
  if [ -e "$isofile" ]; then
    regexp --set=isoname "$isopath/(.*)" "$isofile"
    submenu "$isoname ->" "$isofile" {
      iso_path="$2"
      loopback loop "$iso_path"
      menuentry "openSUSE Tumbleweed Live" {
        bootoptions="isofrom_device=$imgdevpath isofrom_system=$iso_path ramdisk_size=512000 ramdisk_blocksize=4096 splash=silent quiet showopts"
        linux (loop)/boot/*/loader/linux $bootoptions
        initrd (loop)/boot/*/loader/initrd
      }
      menuentry "Failsafe --- openSUSE Tumbleweed Live" {
        bootoptions="isofrom_device=$imgdevpath isofrom_system=$iso_path ramdisk_size=512000 ramdisk_blocksize=4096 splash=silent quiet showopts ide=nodma apm=off noresume edd=off powersaved=off nohz=off highres=off processsor.max+cstate=1 nomodeset x11failsafe"
        linux (loop)/boot/*/loader/linux $bootoptions
        initrd (loop)/boot/*/loader/initrd
      }
    }
  fi
done
