Generate systemd-boot entry by checking bootstrap

This commit is contained in:
theVakhovskeIsTaken 2023-07-13 12:46:13 +00:00
parent a0e3ebdd4c
commit 3b63d82de4
4 changed files with 15 additions and 14 deletions

View File

@ -1,6 +0,0 @@
title HoloISO installer (beta, with LTS)
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux-lts
initrd /%INSTALL_DIR%/boot/intel-ucode.img
initrd /%INSTALL_DIR%/boot/amd-ucode.img
initrd /%INSTALL_DIR%/boot/x86_64/initramfs-linux-lts.img
options archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% cow_spacesize=10G copytoram

View File

@ -1,6 +0,0 @@
title HoloISO installer (beta, with SD 5.13)
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux-neptune
initrd /%INSTALL_DIR%/boot/intel-ucode.img
initrd /%INSTALL_DIR%/boot/amd-ucode.img
initrd /%INSTALL_DIR%/boot/x86_64/initramfs-linux-neptune.img
options archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% cow_spacesize=10G copytoram

View File

@ -1,2 +1 @@
timeout 15
default 01-archiso-x86_64-ram-linux-neptune.conf

14
gen_entries.sh Normal file
View File

@ -0,0 +1,14 @@
#!/bin/bash
PROFILEDIR=$1
count=1
for kernel in $(cat ${PROFILEDIR}/kernel_list.bootstrap)
do
kernel=$(echo $kernel | sed 's/.*linux/linux/g' | sed 's/.*headers//g')
if [ -z "$kernel" ]; then
continue
fi
echo -e "title HoloISO installer (${kernel}, Copy to RAM)\nlinux /%INSTALL_DIR%/boot/x86_64/vmlinuz-${kernel}\ninitrd /%INSTALL_DIR%/boot/intel-ucode.img\ninitrd /%INSTALL_DIR%/boot/amd-ucode.img\ninitrd /%INSTALL_DIR%/boot/x86_64/initramfs-${kernel}.img\noptions archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL% cow_spacesize=10G copytoram" > ${PROFILEDIR}/efiboot/loader/entries/$count-$kernel-copytoram.conf
count=$((count+1))
echo -e "title HoloISO installer (${kernel})\nlinux /%INSTALL_DIR%/boot/x86_64/vmlinuz-${kernel}\ninitrd /%INSTALL_DIR%/boot/intel-ucode.img\ninitrd /%INSTALL_DIR%/boot/amd-ucode.img\ninitrd /%INSTALL_DIR%/boot/x86_64/initramfs-${kernel}.img\noptions archisobasedir=%INSTALL_DIR% archisolabel=%ARCHISO_LABEL%" > ${PROFILEDIR}/efiboot/loader/entries/$count-$kernel.conf
count=$((count+1))
done