Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
randompersononinternet69 committed Jun 23, 2024
1 parent f0bc9a3 commit f0d6688
Show file tree
Hide file tree
Showing 7 changed files with 124 additions and 88 deletions.
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Here's a guide on how to make a pull request, if you're new to GitHub: https://d

## Table of Contents
- [Preview](#preview)
- [Supported architectures](#)
- [Supported types of files](#supported-types-of-files)
- [Download](download-g2fm-here.)
- [Build](#build)
Expand All @@ -30,6 +31,8 @@ Here's a guide on how to make a pull request, if you're new to GitHub: https://d
- [Related projects](#related-projects)
## Preview
![](https://i.imgur.com/zgz3Xeb.png)
## Supported architectures
ARM64, x86, x86_64.
## Supported types of files

| Type | i386-pc | i386-efi | x86_64-efi |
Expand All @@ -56,17 +59,17 @@ Here's a guide on how to make a pull request, if you're new to GitHub: https://d
## Boot
### It is recommended to use g2fm-multiarch ISO.
### i386-pc
DO NOT boot g2fm.iso with memdisk!
#### GRUB4DOS
**DO NOT boot g2fm.iso with memdisk!**
#### GRUB4DOS / GRUB Legacy
map --mem /g2fm.iso (0xff)
map --hook
chainloader (0xff)
#### GRUB 2
#### GRUB2
linux /loadfm
initrd /g2fm.iso
### x86_64-efi

#### GRUB 2
#### GRUB2

chainloader /g2fmx64.efi
#### rEFInd
Expand Down
24 changes: 24 additions & 0 deletions boot/grubfm/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,30 @@ export gfxmode=auto;
export gfxpayload=keep;
terminal_output gfxterm;
echo Starting G2FM beta...
# The following code is from agFM (a1ive's grub2 file manager) for Easy2Boot
set CPU64=false; set CPU32=false; set MBR=false; set EFI=false; set EFI64=false; set EFI32=false; set MBR32=false; set MBR64=false
set CPU32=true
if cpuid -l; then set CPU64=true; fi
if [ "${grub_cpu}" == "x86_64" ]; then set CPU64=true; fi
if $CPU64 == true ; then set CPU32=false ; fi
if [ "${grub_platform}" == "efi" ]; then set EFI=true; else set MBR=true; fi
if [ "${grub_cpu}" == "x86_64" -a $EFI = true ]; then set EFI64=true; fi
if [ "${grub_cpu}" == "i386" -a $EFI = true ]; then set EFI32=true; fi
if [ $CPU64 = true -a $MBR = true ]; then set MBR64=true; fi
if [ $CPU32 = true -a $MBR = true ]; then set MBR32=true; fi

export MBR EFI MBR32 MBR64 EFI32 EFI64 CPU32 CPU64

if $MBR; then echo Legacy\\MBR\\CSM ; fi
if $EFI64; then echo -n "UEFI64 - "; fi
if $EFI32; then echo -n "UEFI32 - "; fi
if $CPU32; then echo "32-bit CPU"; fi
if $CPU64; then echo "64-bit CPU"; fi
if [ "$grub_secureboot" = "Enabled" ]; then set color_normal=white/red; fi
echo Secure Boot: $grub_secureboot
set color_normal=yellow/black
echo Boot drive: $bootdev
echo RAM: ${RAM} MB
export pager=0;
cat --set=modlist ${prefix}/insmod.lst;
for module in ${modlist};
Expand Down
12 changes: 6 additions & 6 deletions boot/grubfm/rules/generic/dummy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,26 @@ then
export theme=${theme_fm};
fi;

hiddenentry " " --hotkey f1 {
menuentry "Hardware Info " --hotkey f1 {
configfile ${prefix}/hwinfo.sh;
}

hiddenentry " " --hotkey f2 {
menuentry "File manager" --hotkey f2 {
grubfm_open "${grubfm_file}";
}

hiddenentry " " --hotkey f3 {
menuentry "Detect operating systems" --hotkey f3 {
configfile ${prefix}/osdetect.sh;
}

hiddenentry " " --hotkey f4 {
menuentry "Settings" --hotkey f4 {
configfile ${prefix}/settings.sh;
}

hiddenentry " " --hotkey f5 {
menuentry "Utitlites" --hotkey f5 {
configfile ${prefix}/util.sh;
}

hiddenentry " " --hotkey f6 {
menuentry "Power Options" --hotkey f6 {
configfile ${prefix}/power.sh;
}
1 change: 1 addition & 0 deletions boot/grubfm/rules/generic/kernel.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ fi;
if file --is-x86-bios-bootsector "${grubfm_file}";
then
menuentry $"Chainload BIOS Boot Sector" --class exe {
echo "Booting ${grubfm_file}"
chainloader --force "${grubfm_file}";
}
fi;
2 changes: 1 addition & 1 deletion boot/grubfm/rules/iso/grubcfg_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ then
set grubfm_test=0;
fi;

source ${prefix}/rules/iso/loop_detect.sh;
source ${prefix}/rules/iso/grubcfg_detect.sh;
loopback -d loop;
fi;
Loading

0 comments on commit f0d6688

Please sign in to comment.