# Copy Porteus-XFCE.iso and Porteus-XFCE.mnu to the /_ISO/Linux/MNU folder (or any similar 3rd level folder)
# You can create the /porteus file using the RMPrepUSB Create Ext2 FS button (volume name=filename=porteus)

iftitle [if exist $HOME$/Porteus-XFCE.iso] Porteus XCFE Graphics mode Persistent\n Run Porteus the best way we can. Try to autoconfigure graphics card and use the maximum allowed resolution.\nUse /porteus as changes filesystem.
set ISO=Porteus-XFCE.iso
if "%E2BDEV%"=="" set E2BDEV=hd0 && pause E2BDEV forced to hd0!
if exist CD echo WARNING: Cannot use partnew command! && pause && configfile (bd)/menu.lst
partnew (%E2BDEV%,3) 0x0 $HOME$/%ISO%
map $HOME$/%ISO% (0xff)

#enable parttype output
debug 1
parttype (%E2BDEV%,2) | set check=
debug off
set check=%check:~-5,4%
if "%check%"=="0x00" partnew (%E2BDEV%,2) 0 0 0
if not "%check%"=="0x00" echo WARNING: PTN TABLE 3 IS ALREADY IN USE! && pause
debug 1
if not exist /porteus echo WARNING: /porteus persistence file not found! && pause
errorcheck off
if "%check%"=="0x00" partnew (%E2BDEV%,2) 0x0 /porteus

map --hook
chainloader (0xff)
root (0xff)
kernel /boot/syslinux/vmlinuz changes=LABEL:porteus/
#kernel /boot/syslinux/vmlinuz from=$HOME$/%ISO% changes=LABEL:porteus/
initrd /boot/syslinux/initrd.xz



    





