An 'Internet Connection Check' stage has been added. The installer now checks for an active internet connection and exits if none is found.

The 'UEFi Mode Check' stage now shows UEFI bitness.
The 'System Clock Update' stage now shows relevant info.
A few cosmetic changes took place.
This commit is contained in:
Jane Doe 2024-05-04 15:09:51 +00:00
parent 5b19fdb3a9
commit 1b3c27be86

View file

@ -309,17 +309,15 @@ Enter a number: "
########################################################################################### ###########################################################################################
uefi_check (){ uefi_check (){
local prompt="UEFI Mode" bootmode=$(cat /sys/firmware/efi/fw_platform_size)
local prompt="UEFI "${bootmode}"-bit Mode"
sleep 0.5 sleep 0.5
NC " NC "
______________________________ ______________________________
${purple}###${nc} UEFI Mode Verification ${purple}###${nc} ${purple}###${nc} UEFI Mode Verification ${purple}###${nc}
" "
if [[ -e /sys/firmware/efi/efivars ]]; then if [[ "${bootmode}" == "64" || "${bootmode}" == "32" ]]; then
ok ok
else else
RED " RED "
@ -328,6 +326,24 @@ ${purple}###${nc} UEFI Mode Verification ${purple}###${nc}
fi fi
} }
########################################################################################### ###########################################################################################
connection_check (){
local prompt="Internet Connection"
sleep 0.5
NC "
_________________________________
${purple}###${nc} Internet Connection Check ${purple}###${nc}
"
if ping -c 3 archlinux.org > /dev/null 2>&1; then
ok
else
RED "
[!] An active Internet connection is mandatory to continue "
abort
fi
}
###########################################################################################
upd_clock (){ upd_clock (){
local prompt="System Clock" local prompt="System Clock"
@ -337,7 +353,7 @@ ___________________________
${purple}###${nc} System Clock Update ${purple}###${nc} ${purple}###${nc} System Clock Update ${purple}###${nc}
" "
timedatectl set-ntp true timedatectl
ok ok
} }
########################################################################################### ###########################################################################################
@ -387,7 +403,7 @@ ${purple}###${nc} Main Menu ${purple}###${nc}
[3] Disk Management [3] Disk Management
[4] Start Installation (${cyan}Auto-Navigation${nc}) " [4] ${cyan}Start Auto-Navigated Installation${nc} "
BLUE " BLUE "
@ -4672,6 +4688,7 @@ NVIDIAHOOK
${bwhite}Press any key to start" ${bwhite}Press any key to start"
read -s -n 1 read -s -n 1
uefi_check uefi_check
connection_check
upd_clock upd_clock
dtct_microcode dtct_microcode
until main_menu; do : ; done until main_menu; do : ; done