From 79365921800b676d4d607585a48e6a90937c30bc Mon Sep 17 00:00:00 2001 From: Agus Lopez Date: Wed, 25 Oct 2017 16:25:35 +0200 Subject: [PATCH 01/10] Use submenu to boot ISO files Put the option to boot a supported ISO/kernel file in a submenu. --- mbusb.cfg | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/mbusb.cfg b/mbusb.cfg index 346df545..091756b9 100644 --- a/mbusb.cfg +++ b/mbusb.cfg @@ -18,6 +18,7 @@ fi # MultiBoot USB menu submenu "Multiboot ->" { + # Warning for 32-bit systems if ! cpuid -l; then clear @@ -30,9 +31,12 @@ submenu "Multiboot ->" { echo fi - # Load configuration files - echo -n "Loading configuration files... " - for cfgfile in $prefix/mbusb.d/*.d/*.cfg; do - source "$cfgfile" - done + # Load configuration for ISO/kernel files + submenu "Boot supported ISO/kernel files ->" { + echo -n "Loading configuration files... " + for cfgfile in $prefix/mbusb.d/*.d/*.cfg; do + source "$cfgfile" + done + } + } From afdb139d3118f041b10d926112760fbd277db23e Mon Sep 17 00:00:00 2001 From: Agus Lopez Date: Wed, 25 Oct 2017 16:26:08 +0200 Subject: [PATCH 02/10] Add submenu to use MEMDISK with ISO files For each available ISO file, show a menu entry to boot it using MEMDISK. --- mbusb.cfg | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/mbusb.cfg b/mbusb.cfg index 091756b9..ffc7e5d0 100644 --- a/mbusb.cfg +++ b/mbusb.cfg @@ -39,4 +39,33 @@ submenu "Multiboot ->" { done } + # Use MEMDISK to load ISO files + submenu "Use MEMDISK to boot ISO files ->" { + echo -n "Looking for ISO files... " + for isofile in $isopath/*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + menuentry "$isoname" "$isofile" { + iso_path="$2" + bootoptions="iso raw" + linux16 $prefix/memdisk $bootoptions + initrd16 $iso_path + } + fi + done + echo + echo -n "Looking for ISO files... " + for imgfile in $isopath/*.img; do + if [ -e "$imgfile" ]; then + regexp --set=imgname "$isopath/(.*)" "$imgfile" + menuentry "$imgname" "$imgfile" { + img_path="$2" + bootoptions="raw" + linux16 $prefix/memdisk $bootoptions + initrd16 $img_path + } + fi + done + } + } From 48b0873d627d6326acd3ccb3cf32c8b407b28a55 Mon Sep 17 00:00:00 2001 From: Agus Lopez Date: Wed, 25 Oct 2017 16:27:19 +0200 Subject: [PATCH 03/10] Add submenu to look for some boot files For each available ISO file, mount it and look for some common boot files (e.g. GRUB, SYSLINUX, etc.) and show menu entries for each one of those. This can be used to test unsupported ISO files. --- mbusb.cfg | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) diff --git a/mbusb.cfg b/mbusb.cfg index ffc7e5d0..7e7bf29f 100644 --- a/mbusb.cfg +++ b/mbusb.cfg @@ -16,6 +16,59 @@ if [ -e "$prefix/mbusb.cfg.local" ]; then source "$prefix/mbusb.cfg.local" fi +# Function to look for boot files +function search_files { + root="$1" + + insmod bitmap + insmod jpeg + insmod png + insmod tga + + for grubfile in \ + /boot/grub/loopback.cfg \ + /boot/grub/grub.cfg \ + /boot/grub/x86_64-efi/grub.cfg \ + /EFI/BOOT/grub.cfg; do + if [ -e "$grubfile" ]; then + menuentry "GRUB boot ($grubfile)" "$grubfile" { + grub_file="$2" + configfile "$grub_file" + } + fi + done + + for syslinuxfile in \ + /isolinux.cfg \ + /syslinux.cfg \ + /isolinux/isolinux.cfg \ + /isolinux/syslinux.cfg \ + /syslinux/isolinux.cfg \ + /boot/isolinux.cfg \ + /boot/isolinux/isolinux.cfg \ + /boot/syslinux.cfg \ + /boot/syslinux/isolinux.cfg \ + /boot/syslinux/syslinux.cfg; do + if [ -e "$syslinuxfile" ]; then + menuentry "SYSLINUX boot ($syslinuxfile)" "$syslinuxfile" { + syslinux_file="$2" + syslinux_configfile -i "$syslinux_file" + } + fi + done + + for legacyfile in \ + /boot/grub/menu.lst \ + /menu.lst; do + if [ -e "$legacyfile" ]; then + menuentry "GRUB legacy boot ($legacyfile)" "$legacyfile" { + legacy_file="$2" + legacy_configfile "$legacy_file" + } + fi + done +} + # MultiBoot USB menu submenu "Multiboot ->" { @@ -39,6 +92,25 @@ submenu "Multiboot ->" { done } + # Search ISO files for boot files + submenu "Auto-detect ISO's configfiles ->" { + echo -n "Looking for ISO files... " + for isofile in $isopath/*.iso $isopath/*.img; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + export iso_path + search --set=root --file "$iso_path" + loopback loop "$iso_path" + root=(loop) + # Look for boot files + search_files $root + } + fi + done + } + # Use MEMDISK to load ISO files submenu "Use MEMDISK to boot ISO files ->" { echo -n "Looking for ISO files... " From d759ab692768553debe14d91bbcd882545f6656d Mon Sep 17 00:00:00 2001 From: Agus Lopez Date: Wed, 25 Oct 2017 16:29:04 +0200 Subject: [PATCH 04/10] Add submenu to look for bootable partitions Look for partitions in the current USB drive that have either some common boot files (e.g. GRUB, SYSLINUX, etc.) or an EFI binary. This can be used to boot a Windows installation CD by creating a partition and dumping the contents of the CD into it. --- mbusb.cfg | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/mbusb.cfg b/mbusb.cfg index 7e7bf29f..a7a0c6c1 100644 --- a/mbusb.cfg +++ b/mbusb.cfg @@ -1,7 +1,9 @@ # Partition holding files +regexp --set=rootdisk "^(.*),.*" "$root" +regexp --set=rootpartnum "^.*,.*([0-9]+)" "$root" probe -u $root --set=rootuuid set imgdevpath="/dev/disk/by-uuid/$rootuuid" -export imgdevpath rootuuid +export imgdevpath rootuuid rootdisk rootpartnum # Custom variables set isopath="/boot/isos" @@ -67,6 +69,18 @@ function search_files { } fi done + + if [ "x$grub_platform" == "xefi" ]; then + for efifile in /efi/boot/bootx64.efi; do + if [ -e "$efifile" ]; then + menuentry "EFI boot ($efifile)" "$efifile" { + efi_file="$2" + chainloader "$efi_file" + } + fi + done + fi + } # MultiBoot USB menu @@ -92,6 +106,22 @@ submenu "Multiboot ->" { done } + # Search partitions for boot files + submenu "Auto-detect bootable partitions ->" { + echo -n "Searching pendrive's partitions... " + for part in ($rootdisk,*); do + regexp --set=partnum "^.*,.*([0-9]+)" "$part" + if [ "$partnum" -le "$rootpartnum" ]; then continue; fi + submenu "$part ->" "$part" { + part_name="$2" + probe --fs-uuid $part_name --set=part_uuid + search --fs-uuid --no-floppy --hint=$part_name --set=root $part_uuid + # Look for boot files + search_files $root + } + done + } + # Search ISO files for boot files submenu "Auto-detect ISO's configfiles ->" { echo -n "Looking for ISO files... " From b0d0310e0fe0e6b6cc2869a69566485975d5bc92 Mon Sep 17 00:00:00 2001 From: Nedyalko Andreev Date: Tue, 7 Nov 2017 13:01:47 +0200 Subject: [PATCH 05/10] Add support for ReactOS --- docs/_misc/reactos.md | 49 +++++++++++++++++++++++++++++++++++ mbusb.d/reactos.d/generic.cfg | 11 ++++++++ 2 files changed, 60 insertions(+) create mode 100644 docs/_misc/reactos.md create mode 100644 mbusb.d/reactos.d/generic.cfg diff --git a/docs/_misc/reactos.md b/docs/_misc/reactos.md new file mode 100644 index 00000000..97528062 --- /dev/null +++ b/docs/_misc/reactos.md @@ -0,0 +1,49 @@ +--- +title: ReactOS +homepage: https://reactos.org/ +download: https://reactos.org/download +cfgdir: reactos.d +layout: default +--- + +# {{ page.title }} + +> ReactOS is a free and open-source operating system based on the best design +> principles found in the Windows NT architecture. Written completely from +> scratch, ReactOS is not a Linux-based system and it shares none of the UNIX +> architecture. The main goal of the ReactOS project is to provide an operating +> system which is binary compatible with Windows. This will allow Windows +> applications and drivers to run as they would on a Windows system. Additionally, +> the look and feel of the Windows operating system is used, such that people +> accustomed to the familiar user interface of Windows would find using ReactOS +> straightforward. The ultimate goal of ReactOS is to allow people to use it as +> an alternative to Windows without the need to change software they are used to. +> +> -- [DistroWatch][] + + +{% if page.cfgdir %} +## Configuration + +- [Project's files for {{ page.title }}][config] +{% endif %} + + +## Supported releases + +- BootCD ISO for installation (using [MEMDISK][]) +- LoveCD ISO (using [MEMDISK][]) + + +## Links + +- [Official homepage]({{ page.homepage }}) +- [Official download page]({{ page.download }}) +- [{{ page.title }} at DistroWatch][distrowatch] +- [{{ page.title }} at Wikipedia][wikipedia] + + +[config]: {{ site.github.repository_url | append: "/tree/master/mbusb.d/" | append: page.cfgdir }} +[distrowatch]: https://distrowatch.com/table.php?distribution=reactos +[memdisk]: http://www.syslinux.org/wiki/index.php?title=MEMDISK +[wikipedia]: https://en.wikipedia.org/wiki/ReactOS diff --git a/mbusb.d/reactos.d/generic.cfg b/mbusb.d/reactos.d/generic.cfg new file mode 100644 index 00000000..371111bc --- /dev/null +++ b/mbusb.d/reactos.d/generic.cfg @@ -0,0 +1,11 @@ +for isofile in $isopath/ReactOS*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + menuentry "$isoname (memdisk)" "$isofile" { + iso_path="$2" + bootoptions="iso raw" + linux16 $prefix/memdisk $bootoptions + initrd16 $iso_path + } + fi +done From c94dd23eaa5e950f27e5ddfc8c608b284e6969c9 Mon Sep 17 00:00:00 2001 From: Max O'Cull Date: Sun, 17 Dec 2017 20:58:31 -0500 Subject: [PATCH 06/10] Add base configuration for AntivirusLiveCD, Bitkey, ReactOS, Scientific Linux, Ubuntu Studio, and Windows 10 --- mbusb.d/antiviruslive.d/generic.cfg | 19 +++++++++++++++++++ mbusb.d/bitkey.d/generic.cfg | 24 ++++++++++++++++++++++++ mbusb.d/reactos.d/generic.cfg | 12 ++++++++++++ mbusb.d/scientificlinux.d/generic.cfg | 25 +++++++++++++++++++++++++ mbusb.d/ubuntustudio.d/generic.cfg | 14 ++++++++++++++ mbusb.d/windows.d/iso-generic10.cfg | 12 ++++++++++++ 6 files changed, 106 insertions(+) create mode 100644 mbusb.d/antiviruslive.d/generic.cfg create mode 100644 mbusb.d/bitkey.d/generic.cfg create mode 100644 mbusb.d/reactos.d/generic.cfg create mode 100644 mbusb.d/scientificlinux.d/generic.cfg create mode 100644 mbusb.d/ubuntustudio.d/generic.cfg create mode 100644 mbusb.d/windows.d/iso-generic10.cfg diff --git a/mbusb.d/antiviruslive.d/generic.cfg b/mbusb.d/antiviruslive.d/generic.cfg new file mode 100644 index 00000000..e9e162e2 --- /dev/null +++ b/mbusb.d/antiviruslive.d/generic.cfg @@ -0,0 +1,19 @@ +for isofile in $isopath/AntivirusLiveCD-*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + loopback loop "$iso_path" + menuentry "AntivirusLiveCD with Default Display" { + bootoptions="isoboot=$iso_path rw root=/dev/ram0 vga=normal" + linux (loop)/boot/bzImage $bootoptions + initrd (loop)/boot/initrd.gz + } + menuentry "AntivirusLiveCD with VESA Framebuffer" { + bootoptions="isoboot=$iso_path rw root=/dev/ram0 vga=ask" + linux (loop)/boot/bzImage $bootoptions + initrd (loop)/boot/initrd.gz + } + } + fi +done diff --git a/mbusb.d/bitkey.d/generic.cfg b/mbusb.d/bitkey.d/generic.cfg new file mode 100644 index 00000000..c895fc00 --- /dev/null +++ b/mbusb.d/bitkey.d/generic.cfg @@ -0,0 +1,24 @@ +for isofile in $isopath/turnkey-bitkey-*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + loopback loop "$iso_path" + menuentry "Cold Offline: Create wallet, sign transactions" { + bootoptions="boot=casper isoboot=$iso_path rw root=/dev/ram showmounts toram bitkey=cold-offline --" + linux (loop)/casper/vmlinuz $bootoptions + initrd (loop)/casper/initrd.gz + } + menuentry "Cold Online: Watch wallet, prepare transactions" { + bootoptions="boot=casper isoboot=$iso_path rw root=/dev/ram showmounts toram bitkey=cold-online --" + linux (loop)/casper/vmlinuz $bootoptions + initrd (loop)/casper/initrd.gz + } + menuentry "Hot Online: Create & watch wallet, prepare & sign transactions" { + bootoptions="boot=casper isoboot=$iso_path rw root=/dev/ram showmounts toram bitkey=hot-online --" + linux (loop)/casper/vmlinuz $bootoptions + initrd (loop)/casper/initrd.gz + } + } + fi +done diff --git a/mbusb.d/reactos.d/generic.cfg b/mbusb.d/reactos.d/generic.cfg new file mode 100644 index 00000000..c7a10cc6 --- /dev/null +++ b/mbusb.d/reactos.d/generic.cfg @@ -0,0 +1,12 @@ +for isofile in $isopath/ReactOS-*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + loopback loop "$iso_path" + menuentry "ReactOS Live" { + multiboot (loop)/loader/setupldr.sys + } + } + fi +done diff --git a/mbusb.d/scientificlinux.d/generic.cfg b/mbusb.d/scientificlinux.d/generic.cfg new file mode 100644 index 00000000..2f1499b9 --- /dev/null +++ b/mbusb.d/scientificlinux.d/generic.cfg @@ -0,0 +1,25 @@ +for isofile in $isopath/SL-*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + loopback loop "$iso_path" + probe --label --set=cd_label (loop) + menuentry "Start Scientific Linux" { + bootoptions="iso-scan/filename=$iso_path root=live:CDLABEL=$cd_label rootfstype=auto ro rhgb rd.luks=0 rd.md=0 rd.dm=0 rd.live.image quiet" + linux (loop)/isolinux/vmlinuz0 $bootoptions + initrd (loop)/isolinux/initrd0.img + } + menuentry "Start Scientific Linux in basic graphics mode" { + bootoptions="iso-scan/filename=$iso_path root=live:CDLABEL=$cd_label rootfstype=auto ro rhgb rd.luks=0 rd.md=0 rd.dm=0 rd.live.image nomodeset quiet" + linux (loop)/isolinux/vmlinuz0 $bootoptions + initrd (loop)/isolinux/initrd0.img + } + menuentry "Test this media & start Scientific Linux" { + bootoptions="iso-scan/filename=$iso_path root=live:CDLABEL=$cd_label rootfstype=auto ro rhgb rd.luks=0 rd.md=0 rd.dm=0 rd.live.image rd.live.check quiet" + linux (loop)/isolinux/vmlinuz0 $bootoptions + initrd (loop)/isolinux/initrd0.img + } + } + fi +done diff --git a/mbusb.d/ubuntustudio.d/generic.cfg b/mbusb.d/ubuntustudio.d/generic.cfg new file mode 100644 index 00000000..c14465bd --- /dev/null +++ b/mbusb.d/ubuntustudio.d/generic.cfg @@ -0,0 +1,14 @@ +for isofile in $isopath/ubuntustudio-*.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname (loopback.cfg) ->" "$isofile" { + iso_path="$2" + export iso_path + search --set=root --file "$iso_path" + loopback loop "$iso_path" + root=(loop) + configfile /boot/grub/loopback.cfg + loopback --delete loop + } + fi +done diff --git a/mbusb.d/windows.d/iso-generic10.cfg b/mbusb.d/windows.d/iso-generic10.cfg new file mode 100644 index 00000000..d3c27017 --- /dev/null +++ b/mbusb.d/windows.d/iso-generic10.cfg @@ -0,0 +1,12 @@ +for isofile in $isopath/Win10_*_x64.iso; do + if [ -e "$isofile" ]; then + regexp --set=isoname "$isopath/(.*)" "$isofile" + submenu "$isoname ->" "$isofile" { + iso_path="$2" + export iso_path + search --set=root --file "$iso_path" + loopback loop "$iso_path" + chainloader (loop)/efi/boot/bootx64.efi + } + fi +done From fa48998ba9634054bdfc03607da157dd2b8e7b42 Mon Sep 17 00:00:00 2001 From: Max O'Cull Date: Sun, 17 Dec 2017 22:15:17 -0500 Subject: [PATCH 07/10] Add Thinstation; change ReactOS and Windows to partition chainloading --- mbusb.d/bitkey.d/generic.cfg | 1 + mbusb.d/reactos.d/generic.cfg | 12 ------------ mbusb.d/reactos.d/partition-generic.cfg | 8 ++++++++ .../iso-generic10.cfg => thinstation.d/generic.cfg} | 8 +++++--- mbusb.d/windows.d/partition-win10.cfg | 8 ++++++++ 5 files changed, 22 insertions(+), 15 deletions(-) delete mode 100644 mbusb.d/reactos.d/generic.cfg create mode 100644 mbusb.d/reactos.d/partition-generic.cfg rename mbusb.d/{windows.d/iso-generic10.cfg => thinstation.d/generic.cfg} (50%) create mode 100644 mbusb.d/windows.d/partition-win10.cfg diff --git a/mbusb.d/bitkey.d/generic.cfg b/mbusb.d/bitkey.d/generic.cfg index c895fc00..4d776392 100644 --- a/mbusb.d/bitkey.d/generic.cfg +++ b/mbusb.d/bitkey.d/generic.cfg @@ -1,5 +1,6 @@ for isofile in $isopath/turnkey-bitkey-*.iso; do if [ -e "$isofile" ]; then + insmod test regexp --set=isoname "$isopath/(.*)" "$isofile" submenu "$isoname ->" "$isofile" { iso_path="$2" diff --git a/mbusb.d/reactos.d/generic.cfg b/mbusb.d/reactos.d/generic.cfg deleted file mode 100644 index c7a10cc6..00000000 --- a/mbusb.d/reactos.d/generic.cfg +++ /dev/null @@ -1,12 +0,0 @@ -for isofile in $isopath/ReactOS-*.iso; do - if [ -e "$isofile" ]; then - regexp --set=isoname "$isopath/(.*)" "$isofile" - submenu "$isoname ->" "$isofile" { - iso_path="$2" - loopback loop "$iso_path" - menuentry "ReactOS Live" { - multiboot (loop)/loader/setupldr.sys - } - } - fi -done diff --git a/mbusb.d/reactos.d/partition-generic.cfg b/mbusb.d/reactos.d/partition-generic.cfg new file mode 100644 index 00000000..ef289838 --- /dev/null +++ b/mbusb.d/reactos.d/partition-generic.cfg @@ -0,0 +1,8 @@ +# Checks for a ReactOS ISO written onto the USB. This may be the only way to boot it with GRUB2. +search --set=reactostest --label REACTOS > /dev/null 2>&1 +if [ -n "$reactostest" ]; then + menuentry "Start Live React OS" { + set root="$reactostest" + chainloader /loader/setupldr.sys + } +fi diff --git a/mbusb.d/windows.d/iso-generic10.cfg b/mbusb.d/thinstation.d/generic.cfg similarity index 50% rename from mbusb.d/windows.d/iso-generic10.cfg rename to mbusb.d/thinstation.d/generic.cfg index d3c27017..98ab69cc 100644 --- a/mbusb.d/windows.d/iso-generic10.cfg +++ b/mbusb.d/thinstation.d/generic.cfg @@ -1,12 +1,14 @@ -for isofile in $isopath/Win10_*_x64.iso; do +for isofile in $isopath/TS-Multiclient*.iso; do if [ -e "$isofile" ]; then regexp --set=isoname "$isopath/(.*)" "$isofile" - submenu "$isoname ->" "$isofile" { + submenu "$isoname (isolinux.cfg) ->" "$isofile" { iso_path="$2" export iso_path search --set=root --file "$iso_path" loopback loop "$iso_path" - chainloader (loop)/efi/boot/bootx64.efi + root=(loop) + syslinux_configfile -i /boot/syslinux/syslinux.cfg + loopback --delete loop } fi done diff --git a/mbusb.d/windows.d/partition-win10.cfg b/mbusb.d/windows.d/partition-win10.cfg new file mode 100644 index 00000000..0b025b88 --- /dev/null +++ b/mbusb.d/windows.d/partition-win10.cfg @@ -0,0 +1,8 @@ +# Checks for a Windows 10 ISO written onto the USB. This may be the only way to boot it with GRUB2. +search --set=wintest --label CCCOMA_X64FRE_EN-US_DV9 > /dev/null 2>&1 +if [ -n "$wintest" ]; then + menuentry "Start Live Windows 10" { + set root="$wintest" + chainloader /efi/boot/bootx64.efi + } +fi From 44c12467ecafd58e437f704c87d8bd63f4862a1c Mon Sep 17 00:00:00 2001 From: Max O'Cull Date: Sun, 17 Dec 2017 22:58:56 -0500 Subject: [PATCH 08/10] Change label names; fix proper setting of root --- mbusb.d/reactos.d/partition-generic.cfg | 4 ++-- mbusb.d/windows.d/partition-win10.cfg | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mbusb.d/reactos.d/partition-generic.cfg b/mbusb.d/reactos.d/partition-generic.cfg index ef289838..bf720b18 100644 --- a/mbusb.d/reactos.d/partition-generic.cfg +++ b/mbusb.d/reactos.d/partition-generic.cfg @@ -1,8 +1,8 @@ # Checks for a ReactOS ISO written onto the USB. This may be the only way to boot it with GRUB2. -search --set=reactostest --label REACTOS > /dev/null 2>&1 +search --set=reactostest --label ReactOS if [ -n "$reactostest" ]; then menuentry "Start Live React OS" { - set root="$reactostest" + search --set=root --label ReactOS chainloader /loader/setupldr.sys } fi diff --git a/mbusb.d/windows.d/partition-win10.cfg b/mbusb.d/windows.d/partition-win10.cfg index 0b025b88..bf332cae 100644 --- a/mbusb.d/windows.d/partition-win10.cfg +++ b/mbusb.d/windows.d/partition-win10.cfg @@ -1,8 +1,8 @@ # Checks for a Windows 10 ISO written onto the USB. This may be the only way to boot it with GRUB2. -search --set=wintest --label CCCOMA_X64FRE_EN-US_DV9 > /dev/null 2>&1 +search --set=wintest --label CCCOMA_X64FRE_EN-US_DV9 if [ -n "$wintest" ]; then menuentry "Start Live Windows 10" { - set root="$wintest" + search --set=root --label CCCOMA_X64FRE_EN-US_DV9 chainloader /efi/boot/bootx64.efi } fi From ca2d61339a5def5d6189bf7a6c4b5eeae20ba572 Mon Sep 17 00:00:00 2001 From: Max O'Cull Date: Mon, 18 Dec 2017 22:09:27 -0500 Subject: [PATCH 09/10] Remove partition-based scripts in favor of partition scanning --- mbusb.d/reactos.d/partition-generic.cfg | 8 -------- mbusb.d/windows.d/partition-win10.cfg | 8 -------- 2 files changed, 16 deletions(-) delete mode 100644 mbusb.d/reactos.d/partition-generic.cfg delete mode 100644 mbusb.d/windows.d/partition-win10.cfg diff --git a/mbusb.d/reactos.d/partition-generic.cfg b/mbusb.d/reactos.d/partition-generic.cfg deleted file mode 100644 index bf720b18..00000000 --- a/mbusb.d/reactos.d/partition-generic.cfg +++ /dev/null @@ -1,8 +0,0 @@ -# Checks for a ReactOS ISO written onto the USB. This may be the only way to boot it with GRUB2. -search --set=reactostest --label ReactOS -if [ -n "$reactostest" ]; then - menuentry "Start Live React OS" { - search --set=root --label ReactOS - chainloader /loader/setupldr.sys - } -fi diff --git a/mbusb.d/windows.d/partition-win10.cfg b/mbusb.d/windows.d/partition-win10.cfg deleted file mode 100644 index bf332cae..00000000 --- a/mbusb.d/windows.d/partition-win10.cfg +++ /dev/null @@ -1,8 +0,0 @@ -# Checks for a Windows 10 ISO written onto the USB. This may be the only way to boot it with GRUB2. -search --set=wintest --label CCCOMA_X64FRE_EN-US_DV9 -if [ -n "$wintest" ]; then - menuentry "Start Live Windows 10" { - search --set=root --label CCCOMA_X64FRE_EN-US_DV9 - chainloader /efi/boot/bootx64.efi - } -fi From 5124a1602874a3b440ae374887ef1692629e7dc4 Mon Sep 17 00:00:00 2001 From: Max O'Cull Date: Mon, 18 Dec 2017 22:38:03 -0500 Subject: [PATCH 10/10] Add motherboard BIOS/UEFI settings option --- grub.cfg.example | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/grub.cfg.example b/grub.cfg.example index 20d1b4fc..c7e79360 100644 --- a/grub.cfg.example +++ b/grub.cfg.example @@ -76,6 +76,11 @@ submenu "GRUB2 options ->" { } } +# Motherboard +menuentry "System Settings" { + fwsetup +} + # Reboot menuentry "Reboot" { reboot