This commit is contained in:
mfgbhatti 2022-02-13 12:29:43 +00:00
parent a48e7914ac
commit d888e2f358
1 changed files with 22 additions and 17 deletions

View File

@ -248,28 +248,28 @@ set_filesystem() {
set_partion_layout() { set_partion_layout() {
title "Setup Partioning Layout" title "Setup Partioning Layout"
LAYOUTS=("Default" "LVM" "LVM+LUKS" "Maintain Current") LAYOUTS=("LVM" "LVM+LUKS" "Maintain Current")
PS3="$PROMPT" PS3="$PROMPT"
select OPT in "${LAYOUTS[@]}"; do select OPT in "${LAYOUTS[@]}"; do
if elements_present "$OPT" "${LAYOUTS[@]}"; then if elements_present "$OPT" "${LAYOUTS[@]}"; then
case "$REPLY" in case "$REPLY" in
# 1)
# set_option "LAYOUT" 1
# break
# ;;
1) 1)
set_option "LAYOUT" 1
break
;;
2)
set_option "LVM" 1 set_option "LVM" 1
set_lvm set_lvm
break break
;; ;;
3) 2)
set_lvm set_lvm
set_option "LUKS" 1 set_option "LUKS" 1
set_option "LUKS_PATH" "/dev/mapper/luks" set_option "LUKS_PATH" "/dev/mapper/luks"
set_password "LUKS_PASSWORD" set_password "LUKS_PASSWORD"
break break
;; ;;
4) 3)
echo -ne "Maintaining current settings" echo -ne "Maintaining current settings"
CHOICE=($(lsblk | grep 'part' | awk '{print "/dev/" substr($1,3)}')) CHOICE=($(lsblk | grep 'part' | awk '{print "/dev/" substr($1,3)}'))
if [[ -d "/sys/firmware/efi/" ]]; then if [[ -d "/sys/firmware/efi/" ]]; then
@ -477,14 +477,19 @@ set_desktop() {
set_bootloader() { set_bootloader() {
title "Select your bootloader" title "Select your bootloader"
SELECTION=("GRUB" "Systemd" "UEFI" "None") SELECTION=("Default (GRUB)" "Systemd" "UEFI" "None")
echo "Systemd and UEFI are only available on a UEFI system" echo "Systemd and UEFI are only available on a UEFI system"
echo "None will skip a bootloader and you will not be able to boot" echo "None will skip a bootloader and you will not be able to boot"
PS3="$PROMPT" PS3="$PROMPT"
select OPT in "${SELECTION[@]}"; do select OPT in "${SELECTION[@]}"; do
if elements_present "$OPT" "${SELECTION[@]}"; then if elements_present "$OPT" "${SELECTION[@]}"; then
set_option "BOOTLOADER" "${OPT,,}" if [[ "$OPT" == "Default (GRUB)" ]]; then
break set_option "BOOTLOADER" "grub"
break
else
set_option "BOOTLOADER" "${OPT,,}"
break
fi
else else
invalid_option invalid_option
set_bootloader set_bootloader
@ -520,10 +525,10 @@ make_choice() {
set_keymap set_keymap
ssd_drive ssd_drive
set_btrfs set_btrfs
set_option "LAYOUT" 1
set_option "BOOTLOADER" "grub" set_option "BOOTLOADER" "grub"
set_option "FS" "btrfs" set_option "FS" "btrfs"
set_option "DE" "default" set_option "DESKTOP" "default"
set_option "LAYOUT" 1
break break
;; ;;
@ -558,10 +563,10 @@ make_choice() {
fi fi
done done
} }
background_check # background_check
# write_to_config write_to_config
clear # clear
logo # logo
make_choice # make_choice
# user_info # user_info
# set_partion_layout # set_partion_layout