BOARD: allow FileSystem change for every present type (#175)

* BOARD: firstboot: use while loops instead of sleep

* BOARD: main: run `firstboot` simply in subshell

* firstboot: add SWAP label

* firstboot: allow to redo FS change for every type

* firsboot: rm roundup in BOOT_SIZE of gpt align

* firsboot: FAT32 is in fact vfat type

* add logs for parted cmd in p5 resize - also output LICENSE sign info

* add `FIRSTBOOT=1` opt to rerun flashing wizard
This commit is contained in:
Apaczer
2025-06-08 22:06:39 +02:00
committed by GitHub
parent 9cb29fcc0c
commit ba175a94f3
3 changed files with 161 additions and 63 deletions

View File

@@ -13,7 +13,7 @@ UMTPR_LOGS=/dev/null
GMENU2X_LOGS=/dev/null
# check if it's first boot and turn on messages if yes
if (grep -sq DEBUG\=\1 "${HOME}/options.cfg" || test -r "${BOOTDIR}/firstboot" || test -r "${HOME}/firstboot.completed"); then
if (grep -sq DEBUG\=\1 "${HOME}/options.cfg" || test -r "${BOOTDIR}/firstboot" || test -r "${HOME}/firstboot.completed" || grep -sq FIRSTBOOT\=\1 "${HOME}/options.cfg"); then
DEBUG_MSG="yes"
LOGS="${HOME}/log.txt"
GMENU2X_LOGS="${HOME}/log_gmenu2x.txt" # just standard stdout/stderr
@@ -131,8 +131,12 @@ else
fi
# check if it's first boot and defer to the firstboot script if yes
if grep -sq FIRSTBOOT\=\1 "${HOME}/options.cfg"; then
test -r "${BOOTDIR}/firstboot.done" \
&& sh "${BOOTDIR}/firstboot.done"
fi
if test -r "${BOOTDIR}/firstboot"; then
exec sh "${BOOTDIR}/firstboot"
sh "${BOOTDIR}/firstboot"
elif test -r "${HOME}/firstboot.completed"; then
rm "${HOME}/firstboot.completed"
fi