diff --git a/usr/lib/archboot/installer/autoconfiguration.sh b/usr/lib/archboot/installer/autoconfiguration.sh index 0273e49e0..89b69ce4f 100644 --- a/usr/lib/archboot/installer/autoconfiguration.sh +++ b/usr/lib/archboot/installer/autoconfiguration.sh @@ -8,12 +8,12 @@ _auto_timesetting() { if [[ -e /etc/localtime && ! -e "${_DESTDIR}"/etc/localtime ]]; then _progress "5" "Enable timezone setting on installed system..." cp -a /etc/localtime "${_DESTDIR}"/etc/localtime - read -r -t 2 + sleep 2 fi if [[ -f /etc/adjtime && ! -f "${_DESTDIR}"/etc/adjtime ]]; then _progress "8" "Enable clock setting on installed system..." cp /etc/adjtime "${_DESTDIR}"/etc/adjtime - read -r -t 2 + sleep 2 fi } @@ -47,7 +47,7 @@ _auto_network() cp /etc/systemd/network.conf.d/ipv6-privacy-extensions.conf \ "${_DESTDIR}"/etc/systemd/network.conf.d/ipv6-privacy-extensions.conf fi - read -r -t 2 + sleep 2 } _auto_fstab(){ @@ -61,7 +61,7 @@ _auto_fstab(){ sd -p '^[^#]*' '' "${_DESTDIR}"/etc/fstab sort /tmp/.fstab >>"${_DESTDIR}"/etc/fstab fi - read -r -t 2 + sleep 2 } # add udev rule for schedulers by default @@ -69,7 +69,7 @@ _auto_scheduler () { if [[ ! -f ${_DESTDIR}/etc/udev/rules.d/70-ioschedulers.rules ]]; then _progress "24" "Enable performance ioscheduler settings on installed system..." cp /etc/udev/rules.d/60-ioschedulers.rules "${_DESTDIR}"/etc/udev/rules.d/60-ioschedulers.rules - read -r -t 2 + sleep 2 fi } @@ -78,7 +78,7 @@ _auto_swap () { if [[ ! -f ${_DESTDIR}/etc/sysctl.d/99-sysctl.conf ]]; then _progress "29" "Enable sysctl swap settings on installed system..." cp /etc/sysctl.d/99-sysctl.conf "${_DESTDIR}"/etc/sysctl.d/99-sysctl.conf - read -r -t 2 + sleep 2 fi } @@ -90,7 +90,7 @@ _auto_mdadm() _progress "34" "Enable mdadm settings on installed system..." mdadm -Ds >> "${_DESTDIR}"/etc/mdadm.conf fi - read -r -t 2 + sleep 2 fi } @@ -103,7 +103,7 @@ _auto_luks() { cat /tmp/.crypttab >> "${_DESTDIR}"/etc/crypttab chmod 700 /tmp/passphrase-* 2>"${_NO_LOG}" cp /tmp/passphrase-* "${_DESTDIR}"/etc/ 2>"${_NO_LOG}" - read -r -t 2 + sleep 2 fi } @@ -112,7 +112,7 @@ _auto_pacman_keyring() if ! [[ -d ${_DESTDIR}/etc/pacman.d/gnupg ]]; then _progress "47" "Enable pacman's GPG keyring files on installed system..." cp -ar /etc/pacman.d/gnupg "${_DESTDIR}"/etc/pacman.d &>"${_NO_LOG}" - read -r -t 2 + sleep 2 fi } @@ -121,7 +121,7 @@ _auto_testing() if rg -q '^\[core-testing' /etc/pacman.conf; then _progress "53" "Enable [testing] repository on installed system..." sd '^#(\[[c,e].*-testing\]\n)#' '$1' "${_DESTDIR}"/etc/pacman.conf - read -r -t 2 + sleep 2 fi } @@ -138,7 +138,7 @@ Server = "${_SYNC_URL} EOF cat "${_DESTDIR}"/etc/pacman.d/mirrorlist >> /tmp/inst-mirrorlist mv /tmp/inst-mirrorlist "${_DESTDIR}/etc/pacman.d/mirrorlist" - read -r -t 2 + sleep 2 fi } @@ -146,7 +146,7 @@ _auto_vconsole() { if [[ ! -f ${_DESTDIR}/etc/vconsole.conf ]]; then _progress "69" "Setting keymap and font on installed system..." cp /etc/vconsole.conf "${_DESTDIR}"/etc/vconsole.conf - read -r -t 2 + sleep 2 fi } @@ -154,7 +154,7 @@ _auto_hostname() { if [[ ! -f ${_DESTDIR}/etc/hostname ]]; then _progress "76" "Set default hostname on installed system..." echo "myhostname" > "${_DESTDIR}"/etc/hostname - read -r -t 2 + sleep 2 fi } @@ -166,7 +166,7 @@ _auto_locale() { else echo "LANG=C.UTF-8" > "${_DESTDIR}"/etc/locale.conf echo "LC_COLLATE=C" >> "${_DESTDIR}"/etc/locale.conf - read -r -t 2 + sleep 2 fi fi } @@ -178,7 +178,7 @@ _auto_set_locale() { for i in $(rg -o "^LANG=(.*)\..*" -r '$1' "${_DESTDIR}"/etc/locale.conf); do sd "^#${i}" "${i}" "${_DESTDIR}"/etc/locale.gen done - read -r -t 2 + sleep 2 } _auto_windowkeys() { @@ -199,7 +199,7 @@ _auto_bash(){ ! rg -qw 'custom-bash-options.sh' "${_DESTDIR}/root/.bashrc" &&\ echo ". /etc/profile.d/custom-bash-options.sh" >> "${_DESTDIR}/root/.bashrc" cp /etc/profile.d/custom-bash-options.sh "${_DESTDIR}"/etc/profile.d/ - read -r -t 2 + sleep 2 fi } @@ -246,7 +246,7 @@ _auto_mkinitcpio() { sd " 'fallback'" '' "${_DESTDIR}"/etc/mkinitcpio.d/*.preset # remove fallback initramfs [[ -e "${_DESTDIR}/boot/initramfs-linux-fallback.img" ]] && rm -f "${_DESTDIR}/boot/initramfs-linux-fallback.img" - read -r -t 2 + sleep 2 _AUTO_MKINITCPIO=1 _run_mkinitcpio | _dialog --title " Logging to ${_VC} | ${_LOG} " --gauge "Rebuilding initramfs on installed system..." 6 75 0 _mkinitcpio_error diff --git a/usr/lib/archboot/installer/base.sh b/usr/lib/archboot/installer/base.sh index 4daaad53f..972044f12 100644 --- a/usr/lib/archboot/installer/base.sh +++ b/usr/lib/archboot/installer/base.sh @@ -39,7 +39,7 @@ _geteditor() { _dialog --no-mouse --infobox "Enable nano's syntax highlighting on installed system..." 3 70 rg -q '^include' "${_DESTDIR}/etc/nanorc" || \ echo "include \"/usr/share/nano/*.nanorc\"" >> "${_DESTDIR}/etc/nanorc" - read -r -t 2 + sleep 2 fi ;; "NEOVIM") _EDITOR="nvim" @@ -231,7 +231,7 @@ _mainmenu() { exit 0 ;; "2") _COUNT=0 while true; do - read -r -t 1 + sleep 1 _COUNT=$((_COUNT+1)) # abort after 10 seconds _progress "$((_COUNT*10))" "Rebooting in $((10-_COUNT)) second(s). Don't forget to remove the boot medium!" @@ -241,7 +241,7 @@ _mainmenu() { reboot ;; "3") _COUNT=0 while true; do - read -r -t 1 + sleep 1 _COUNT=$((_COUNT+1)) # abort after 10 seconds _progress "$((_COUNT*10))" "Powering off in $((10-_COUNT)) second(s). Don't forget to remove the boot medium!" diff --git a/usr/lib/archboot/installer/blockdevices.sh b/usr/lib/archboot/installer/blockdevices.sh index 0adb1b22c..88a1baa3f 100644 --- a/usr/lib/archboot/installer/blockdevices.sh +++ b/usr/lib/archboot/installer/blockdevices.sh @@ -284,7 +284,7 @@ _umountall() swapoff -a &>"${_NO_LOG}" umount -R "${_DESTDIR}" _dialog --no-mouse --infobox "Disabled swapspace,\nunmounted already mounted disk devices in ${_DESTDIR}..." 4 70 - read -r -t 3 + sleep 3 fi } @@ -301,7 +301,7 @@ _stopmd() mdadm --manage --stop "/dev/${dev}" &>"${_LOG}" done _dialog --no-mouse --infobox "Removing software raid device(s) done." 3 50 - read -r -t 3 + sleep 3 fi fi _DISABLEMDSB="" @@ -316,7 +316,7 @@ _stopmd() _clean_disk "${dev}" done _dialog --no-mouse --infobox "Removing superblock(s) on software raid devices done." 3 60 - read -r -t 3 + sleep 3 fi } @@ -345,7 +345,7 @@ _stoplvm() pvremove -f "${dev}" 2>"${_NO_LOG}" >"${_LOG}" done _dialog --no-mouse --infobox "Removing logical volume(s), logical group(s)\nand physical volume(s) done." 3 60 - read -r -t 3 + sleep 3 fi } @@ -369,7 +369,7 @@ _stopluks() wipefs -a "${_LUKS_REAL_DEV}" &>"${_NO_LOG}" done _dialog --no-mouse --infobox "Removing luks encrypted device(s) done." 3 50 - read -r -t 3 + sleep 3 fi _DISABLELUKS="" _DETECTED_LUKS="" @@ -384,7 +384,7 @@ _stopluks() wipefs -a "${dev}" &>"${_NO_LOG}" done _dialog --no-mouse --infobox "Removing not running luks encrypted device(s) done." 3 60 - read -r -t 3 + sleep 3 fi [[ -e /tmp/.crypttab ]] && rm /tmp/.crypttab } @@ -498,10 +498,10 @@ _createmd() #shellcheck disable=SC2086 if mdadm --create ${_RAIDDEV} ${_RAIDOPTIONS} ${_DEVS} &>"${_LOG}"; then _dialog --no-mouse --infobox "${_RAIDDEV} created successfully." 3 50 - read -r -t 3 + sleep 3 else _dialog --title " ERROR " --no-mouse --infobox "Creating ${_RAIDDEV} failed." 3 60 - read -r -t 5 + sleep 5 return 1 fi if [[ -n "${_RAID_PARTITION}" ]]; then @@ -573,10 +573,10 @@ _createpv() #shellcheck disable=SC2086 if pvcreate -y ${_DEV} &>"${_LOG}"; then _dialog --no-mouse --infobox "Creating physical volume on ${_DEV} was successful." 3 75 - read -r -t 3 + sleep 3 else _dialog --title " ERROR " --no-mouse --infobox "Creating physical volume on ${_DEV} failed." 3 60 - read -r -t 5 + sleep 5 return 1 fi # run udevadm to get values exported @@ -657,7 +657,7 @@ _createvg() #shellcheck disable=SC2086 if vgcreate ${_VGDEV} ${_PV} &>"${_LOG}"; then _dialog --no-mouse --infobox "Creating Volume Group ${_VGDEV} was successful." 3 60 - read -r -t 3 + sleep 3 else _dialog --msgbox "Error while creating Volume Group ${_VGDEV} (see ${_LOG} for details)." 0 0 return 1 @@ -725,7 +725,7 @@ _createlv() #shellcheck disable=SC2086 if lvcreate ${_LV_EXTRA} -l +100%FREE ${_LV} -n ${_LVDEV} &>"${_LOG}"; then _dialog --no-mouse --infobox "Creating Logical Volume ${_LVDEV} was successful." 3 60 - read -r -t 3 + sleep 3 else _dialog --msgbox "Error while creating Logical Volume ${_LVDEV} (see ${_LOG} for details)." 0 0 return 1 @@ -734,7 +734,7 @@ _createlv() #shellcheck disable=SC2086 if lvcreate ${_LV_EXTRA} -L ${_LV_SIZE} ${_LV} -n ${_LVDEV} &>"${_LOG}"; then _dialog --no-mouse --infobox "Creating Logical Volume ${_LVDEV} was successful." 3 60 - read -r -t 3 + sleep 3 else _dialog --msgbox "Error while creating Logical Volume ${_LVDEV} (see ${_LOG} for details)." 0 0 return 1 @@ -773,7 +773,7 @@ _enter_luks_passphrase () { break else _dialog --no-mouse --infobox "Passphrases didn't match, please enter again." 0 0 - read -r -t 3 + sleep 3 _LUKSPASS="" _LUKSPASS2="" fi @@ -785,7 +785,7 @@ _opening_luks() { while true; do cryptsetup luksOpen "${_DEV}" "${_LUKSDEV}" <"${_LUKSPASSPHRASE}" >"${_LOG}" && break _dialog --no-mouse --infobox "Error: Passphrase didn't match, please enter again" 0 0 - read -r -t 5 + sleep 5 _enter_luks_passphrase || return 1 done if _dialog --yesno "Would you like to save the passphrase of luks device in /etc/$(basename "${_LUKSPASSPHRASE}")?\nName:${_LUKSDEV}" 0 0; then diff --git a/usr/lib/archboot/installer/bootloader_grub.sh b/usr/lib/archboot/installer/bootloader_grub.sh index 20c3d45cf..ebf2e2748 100644 --- a/usr/lib/archboot/installer/bootloader_grub.sh +++ b/usr/lib/archboot/installer/bootloader_grub.sh @@ -253,7 +253,7 @@ _setup_grub_bios() { _grub_install_bios & _progress_wait "11" "99" "Setting up GRUB(2) BIOS..." "0.15" _progress "100" "Setting up GRUB(2) BIOS completed." - read -r -t 2 + sleep 2 } _grub_bios() { @@ -325,7 +325,7 @@ _grub_bios() { _grub_config || return 1 _pacman_hook_grub_bios _dialog --title " Success " --no-mouse --infobox "GRUB(2) BIOS has been installed successfully." 3 55 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else _dialog --msgbox "Error installing GRUB(2) BIOS.\nCheck /tmp/grub_bios_install.log for more info.\n\nYou probably need to install it manually by chrooting into ${_DESTDIR}.\nDon't forget to bind mount /dev and /proc into ${_DESTDIR} before chrooting." 0 0 @@ -356,13 +356,13 @@ _grub_install_uefi_sb() { _setup_grub_uefi() { if [[ -n "${_UEFI_SECURE_BOOT}" ]]; then _progress "50" "Installing fedora's shim and mokmanager..." - read -r -t 2 + sleep 2 # install fedora shim [[ -d ${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT ]] || mkdir -p "${_DESTDIR}"/"${_UEFISYS_MP}"/EFI/BOOT cp -f /usr/share/archboot/bootloader/shim"${_SPEC_UEFI_ARCH}".efi "${_DESTDIR}"/"${_UEFISYS_MP}"/EFI/BOOT/BOOT"${_UEFI_ARCH}".EFI cp -f /usr/share/archboot/bootloader/mm"${_SPEC_UEFI_ARCH}".efi "${_DESTDIR}"/"${_UEFISYS_MP}"/EFI/BOOT/ _progress "100" "Installing fedora's shim and mokmanager completed." - read -r -t 2 + sleep 2 else ## Install GRUB _progress "10" "Setting up GRUB(2) UEFI..." @@ -372,7 +372,7 @@ _setup_grub_uefi() { _progress_wait "11" "99" "Setting up GRUB(2) UEFI..." "0.1" _chroot_umount _progress "100" "Setting up GRUB(2) UEFI completed." - read -r -t 2 + sleep 2 fi _GRUB_UEFI=1 } @@ -387,7 +387,7 @@ _setup_grub_uefi_sb() { _grub_install_uefi_sb & _progress_wait "11" "99" "Setting up GRUB(2) UEFI Secure Boot..." "0.1" _progress "100" "Setting up GRUB(2) UEFI Secure Boot completed." - read -r -t 2 + sleep 2 fi } @@ -412,7 +412,7 @@ _grub_uefi() { rm -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" cp -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/grub/grub${_SPEC_UEFI_ARCH}.efi" "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" _dialog --title " Success " --no-mouse --infobox "GRUB(2) for ${_UEFI_ARCH} UEFI has been installed successfully." 3 60 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 elif [[ -e "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/grub${_SPEC_UEFI_ARCH}.efi" && -n "${_UEFI_SECURE_BOOT}" ]]; then _secureboot_keys || return 1 @@ -423,7 +423,7 @@ _grub_uefi() { _BOOTMGR_LOADER_PATH="/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" _uefi_bootmgr_setup _dialog --title " Success " --no-mouse --infobox "SHIM and GRUB(2) Secure Boot for ${_UEFI_ARCH} has been installed successfully." 3 75 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else _dialog --msgbox "Error installing GRUB(2) for ${_UEFI_ARCH} UEFI.\nCheck /tmp/grub_uefi_${_UEFI_ARCH}_install.log for more info.\n\nYou probably need to install it manually by chrooting into ${_DESTDIR}.\nDon't forget to bind mount /dev, /sys and /proc into ${_DESTDIR} before chrooting." 0 0 diff --git a/usr/lib/archboot/installer/bootloader_limine.sh b/usr/lib/archboot/installer/bootloader_limine.sh index 1882098bd..7503a918b 100644 --- a/usr/lib/archboot/installer/bootloader_limine.sh +++ b/usr/lib/archboot/installer/bootloader_limine.sh @@ -47,7 +47,7 @@ _limine_bios() { if chroot "${_DESTDIR}" limine bios-install "${_PARENT_BOOTDEV}" &>"${_LOG}"; then _pacman_hook_limine_bios _dialog --title " Success " --no-mouse --infobox "LIMINE BIOS has been setup successfully." 3 50 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else @@ -70,10 +70,10 @@ _limine_uefi() { mkdir -p "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT" rm -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" cp -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/LIMINE${_UEFI_ARCH}.EFI" "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" - read -r -t 2 + sleep 2 _pacman_hook_limine_uefi _dialog --title " Success " --no-mouse --infobox "LIMINE has been setup successfully." 3 50 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else diff --git a/usr/lib/archboot/installer/bootloader_pacman_hooks.sh b/usr/lib/archboot/installer/bootloader_pacman_hooks.sh index f02c4b787..f59fa01a3 100644 --- a/usr/lib/archboot/installer/bootloader_pacman_hooks.sh +++ b/usr/lib/archboot/installer/bootloader_pacman_hooks.sh @@ -23,7 +23,7 @@ When = PostTransaction Exec = /usr/bin/systemctl restart systemd-boot-update.service EOF _dialog --title " Automatic SYSTEMD-BOOT Update " --no-mouse --infobox "Automatic SYSTEMD-BOOT update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_limine_bios() { @@ -36,7 +36,7 @@ When = PostTransaction Exec = /usr/bin/sh -c "/usr/bin/cp /usr/share/limine/limine-bios.sys /boot/; /usr/bin/limine bios-install '${_PARENT_BOOTDEV}'" EOF _dialog --title " Automatic LIMINE BIOS Update " --no-mouse --infobox "Automatic LIMINE BIOS update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_limine_uefi() { @@ -50,7 +50,7 @@ Exec = /usr/bin/sh -c "/usr/bin/cp /usr/share/limine/BOOT${_UEFI_ARCH}.EFI /${_U /usr/bin/cp /usr/share/limine/BOOT${_UEFI_ARCH}.EFI /${_UEFISYS_MP}/EFI/BOOT/LIMINE${_UEFI_ARCH}.EFI" EOF _dialog --title " Automatic LIMINE Update " --no-mouse --infobox "Automatic LIMINE update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_refind() { @@ -63,7 +63,7 @@ When = PostTransaction Exec = /usr/bin/sh -c "/usr/bin/cp /usr/share/refind/refind_${_SPEC_UEFI_ARCH}.efi /${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI;/usr/bin/refind-install" EOF _dialog --title " Automatic rEFInd Update " --no-mouse --infobox "Automatic rEFInd update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_grub_bios() { @@ -76,7 +76,7 @@ When = PostTransaction Exec = /usr/bin/sh -c "grub-install --directory='/usr/lib/grub/i386-pc' --target='i386-pc' --boot-directory='/boot' --recheck '${_BOOTDEV}'" EOF _dialog --title " Automatic GRUB Update " --no-mouse --infobox "Automatic GRUB BIOS update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_grub_uefi() { @@ -89,7 +89,7 @@ When = PostTransaction Exec = /usr/bin/sh -c "grub-install --directory='/usr/lib/grub/${_GRUB_ARCH}-efi' --target='${_GRUB_ARCH}-efi' --efi-directory='/${_UEFISYS_MP}' --bootloader-id='GRUB' --recheck" EOF _dialog --title " Automatic GRUB Update " --no-mouse --infobox "Automatic GRUB update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_hook_grub_sb() { @@ -102,7 +102,7 @@ When = PostTransaction Exec = /usr/bin/sh -c "/usr/bin/grub-mkstandalone -d '/usr/lib/grub/${_GRUB_ARCH}-efi' -O '${_GRUB_ARCH}-efi' --sbat=/usr/share/grub/sbat.csv --fonts='ter-u16n' --locales='en@quot' --themes='' -o '/${_GRUB_PREFIX_DIR}/grub${_SPEC_UEFI_ARCH}.efi' 'boot/grub/grub.cfg=/${_GRUB_PREFIX_DIR}/${_GRUB_CFG}';/usr/bin/sbsign --key '/${_KEYDIR}/MOK/MOK.key' --cert '/${_KEYDIR}/MOK/MOK.crt' --output '/${_UEFI_BOOTLOADER_DIR}/grub${_SPEC_UEFI_ARCH}.efi' '/${_UEFI_BOOTLOADER_DIR}/grub${_SPEC_UEFI_ARCH}.efi'" EOF _dialog --title " Automatic GRUB UEFI SB Update " --no-mouse --infobox "Automatic GRUB UEFI SB update has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } _pacman_sign() { @@ -118,5 +118,5 @@ Depends = findutils Depends = grep EOF _dialog --title " Automatic Signing " --no-mouse --infobox "Automatic signing has been enabled successfully:\n\n${_HOOKNAME}" 5 70 - read -r -t 3 + sleep 3 } diff --git a/usr/lib/archboot/installer/bootloader_refind.sh b/usr/lib/archboot/installer/bootloader_refind.sh index 83fc3095b..842fd671a 100644 --- a/usr/lib/archboot/installer/bootloader_refind.sh +++ b/usr/lib/archboot/installer/bootloader_refind.sh @@ -32,14 +32,14 @@ CONFEOF rm -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" rm -f "${_DESTDIR}"/boot/refind_linux.conf cp -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/refind/refind_${_SPEC_UEFI_ARCH}.efi" "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" - read -r -t 2 + sleep 2 _dialog --msgbox "You will now be put into the editor to edit:\nrefind.conf\n\nAfter you save your changes, exit the editor." 8 50 _geteditor || return 1 "${_EDITOR}" "${_REFIND_CONFIG}" cp -f "${_REFIND_CONFIG}" "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/" _pacman_hook_refind _dialog --title " Success " --no-mouse --infobox "rEFInd has been setup successfully." 3 50 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else _dialog --title " ERROR " --msgbox "Setting up rEFInd failed." 5 40 diff --git a/usr/lib/archboot/installer/bootloader_sb.sh b/usr/lib/archboot/installer/bootloader_sb.sh index 587a3c329..5f44ee411 100644 --- a/usr/lib/archboot/installer/bootloader_sb.sh +++ b/usr/lib/archboot/installer/bootloader_sb.sh @@ -18,10 +18,10 @@ _secureboot_keys() { done secureboot-keys.sh -name="${_CN}" "${_DESTDIR}/${_KEYDIR}" &>"${_LOG}" || return 1 _dialog --title " Setup Keys " --no-mouse --infobox "Common name(CN) ${_CN}\nused for your keys in ${_DESTDIR}/${_KEYDIR}" 4 60 - read -r -t 3 + sleep 3 else _dialog --title " Setup Keys " --no-mouse --infobox "-Directory ${_DESTDIR}/${_KEYDIR} exists\n-assuming keys are already created\n-trying to use existing keys now" 5 50 - read -r -t 3 + sleep 3 fi } @@ -41,15 +41,15 @@ _mok_sign () { _MOK_PW=/tmp/.password else _dialog --title " ERROR " --no-mouse --infobox "Password didn't match or was empty, please enter again." 6 65 - read -r -t 3 + sleep 3 fi done mokutil -i "${_DESTDIR}"/"${_KEYDIR}"/MOK/MOK.cer < ${_MOK_PW} >"${_LOG}" rm /tmp/.password _dialog --title " Machine Owner Key " --no-mouse --infobox "Machine Owner Key has been installed successfully." 3 70 - read -r -t 3 + sleep 3 ${_NSPAWN} sbsign --key /"${_KEYDIR}"/MOK/MOK.key --cert /"${_KEYDIR}"/MOK/MOK.crt --output /boot/"${_VMLINUZ}" /boot/"${_VMLINUZ}" &>"${_LOG}" ${_NSPAWN} sbsign --key /"${_KEYDIR}"/MOK/MOK.key --cert /"${_KEYDIR}"/MOK/MOK.crt --output "${_UEFI_BOOTLOADER_DIR}"/grub"${_SPEC_UEFI_ARCH}".efi "${_UEFI_BOOTLOADER_DIR}"/grub"${_SPEC_UEFI_ARCH}".efi &>"${_LOG}" _dialog --title " Kernel And Bootloader Signing " --no-mouse --infobox "/boot/${_VMLINUZ} and ${_UEFI_BOOTLOADER_DIR}/grub${_SPEC_UEFI_ARCH}.efi\n\nhave been signed successfully." 5 60 - read -r -t 3 + sleep 3 } diff --git a/usr/lib/archboot/installer/bootloader_systemd_bootd.sh b/usr/lib/archboot/installer/bootloader_systemd_bootd.sh index c210920a0..cbaec9696 100644 --- a/usr/lib/archboot/installer/bootloader_systemd_bootd.sh +++ b/usr/lib/archboot/installer/bootloader_systemd_bootd.sh @@ -30,7 +30,7 @@ BOOTDEOF "${_EDITOR}" "${_DESTDIR}/${_LOADER_CFG}" _pacman_hook_systemd_bootd _dialog --title " Success " --no-mouse --infobox "SYSTEMD-BOOT has been setup successfully." 3 50 - read -r -t 3 + sleep 3 _S_BOOTLOADER=1 else _dialog --msgbox "Error installing SYSTEMD-BOOT." 0 0 diff --git a/usr/lib/archboot/installer/bootloader_systemd_services.sh b/usr/lib/archboot/installer/bootloader_systemd_services.sh index 976695922..9aa180113 100644 --- a/usr/lib/archboot/installer/bootloader_systemd_services.sh +++ b/usr/lib/archboot/installer/bootloader_systemd_services.sh @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-3.0-or-later # created by Tobias Powalowski _uki_autobuild() { - read -r -t 2 + sleep 2 _progress "50" "Enable automatic UKI creation on installed system..." cat << CONFEOF > "${_DESTDIR}/etc/systemd/system/run_ukify.path" [Unit] diff --git a/usr/lib/archboot/installer/bootloader_uboot.sh b/usr/lib/archboot/installer/bootloader_uboot.sh index 72f7a2770..e41398860 100644 --- a/usr/lib/archboot/installer/bootloader_uboot.sh +++ b/usr/lib/archboot/installer/bootloader_uboot.sh @@ -23,5 +23,5 @@ label linux append ${_KERNEL_PARAMS_COMMON_MOD} EOF _dialog --no-mouse --infobox "UBOOT has been installed successfully." 3 55 - read -r -t 3 + sleep 3 } diff --git a/usr/lib/archboot/installer/bootloader_uki.sh b/usr/lib/archboot/installer/bootloader_uki.sh index ae9dbd1f3..330308614 100644 --- a/usr/lib/archboot/installer/bootloader_uki.sh +++ b/usr/lib/archboot/installer/bootloader_uki.sh @@ -29,9 +29,9 @@ _uki_install() { mkdir -p "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT" rm -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" cp -f "${_DESTDIR}/${_UEFISYS_MP}/EFI/Linux/archlinux-linux.efi" "${_DESTDIR}/${_UEFISYS_MP}/EFI/BOOT/BOOT${_UEFI_ARCH}.EFI" - read -r -t 2 + sleep 2 _progress "100" "Unified Kernel Image has been setup successfully." - read -r -t 2 + sleep 2 _S_BOOTLOADER=1 } @@ -50,6 +50,6 @@ _uki_uefi() { _uki_install | _dialog --title " Logging to ${_VC} | ${_LOG} " --gauge "Setting up Unified Kernel Image..." 6 75 0 else _dialog --title " ERROR " --no-mouse --infobox "Setting up Unified Kernel Image failed!" 3 60 - read -r -t 3 + sleep 3 fi } diff --git a/usr/lib/archboot/installer/btrfs.sh b/usr/lib/archboot/installer/btrfs.sh index f587aebab..50e51fd38 100644 --- a/usr/lib/archboot/installer/btrfs.sh +++ b/usr/lib/archboot/installer/btrfs.sh @@ -197,7 +197,7 @@ _check_btrfs_subvolume(){ for i in $(btrfs subvolume list "${_BTRFSMP}" | cut -d ' ' -f 9); do if echo "${i}" | rg -q "${_BTRFS_SUBVOLUME}"; then _dialog --title " ERROR " --no-mouse --infobox "You have defined 2 identical SUBVOLUMES! Please enter another name." 3 75 - read -r -t 3 + sleep 3 _BTRFS_SUBVOLUME="" fi done @@ -207,7 +207,7 @@ _check_btrfs_subvolume(){ _subvolumes_in_use if echo "${_SUBVOLUME_IN_USE}" | rg -q "${_BTRFS_SUBVOLUME}"; then _dialog --title " ERROR " --no-mouse --infobox "You have defined 2 identical SUBVOLUMES! Please enter another name." 3 75 - read -r -t 3 + sleep 3 _BTRFS_SUBVOLUME="" fi fi @@ -243,7 +243,7 @@ _choose_btrfs_subvolume () { else if [[ -n "${_SUBVOLUMES_DETECTED}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "All subvolumes of the device are already in use.\nSwitching to create a new one now." 4 60 - read -r -t 5 + sleep 5 _prepare_btrfs_subvolume || return 1 fi fi diff --git a/usr/lib/archboot/installer/configuration.sh b/usr/lib/archboot/installer/configuration.sh index a0c40b8f9..ed169cf81 100644 --- a/usr/lib/archboot/installer/configuration.sh +++ b/usr/lib/archboot/installer/configuration.sh @@ -21,10 +21,10 @@ _run_mkinitcpio() { _progress_wait "0" "99" "Rebuilding initramfs on installed system..." "0.1" if [[ -e "/tmp/.mkinitcpio-success" ]]; then _progress "100" "Rebuilding initramfs complete." 6 75 - read -r -t 2 + sleep 2 else _progress "100" "Rebuilding initramfs failed." 6 75 - read -r -t 2 + sleep 2 fi _chroot_umount } @@ -42,7 +42,7 @@ _run_locale_gen() { _locale_gen & _progress_wait "0" "99" "Rebuilding glibc locales on installed system..." "0.05" _progress "100" "Rebuilding glibc locales on installed system complete." 6 75 - read -r -t 2 + sleep 2 } _set_mkinitcpio() { @@ -56,7 +56,7 @@ _check_root_password() { # check if empty password is set if passwd -R "${_DESTDIR}" -S root | rg -q ' NP '; then _dialog --title " Root Account " --no-mouse --infobox "Setup detected no password set for root user.\nPlease set new password now." 4 50 - read -r -t 3 + sleep 3 if _prepare_password Root; then _set_password else @@ -94,7 +94,7 @@ _prepare_password() { break else _dialog --title " ERROR " --no-mouse --infobox "Password didn't match, please enter again." 3 50 - read -r -t 3 + sleep 3 fi done } @@ -103,7 +103,7 @@ _set_password() { passwd -R "${_DESTDIR}" "${_USER}" < /tmp/.password &>"${_NO_LOG}" rm /tmp/.password _dialog --title " Success " --no-mouse --infobox "New password set for ${_USER}." 3 50 - read -r -t 2 + sleep 2 } _set_user() { @@ -160,7 +160,7 @@ _user_management() { usermod -R "${_DESTDIR}" -s "/usr/bin/${_SHELL}" "${i}" &>"${_LOG}" done _dialog --title " Success " --no-mouse --infobox "Default shell set to ${_SHELL}." 3 50 - read -r -t 3 + sleep 3 _NEXTITEM=2 else _NEXTITEM=1 @@ -169,7 +169,7 @@ _user_management() { _set_user || break if rg -q "^${_USER}:" "${_DESTDIR}"/etc/passwd; then _dialog --title " ERROR " --no-mouse --infobox "Username already exists! Please choose an other one." 3 60 - read -r -t 3 + sleep 3 else _ADMIN_ATTR="" if _dialog --defaultno --yesno "Enable ${_USER} as Administrator and part of wheel group?" 5 60; then @@ -181,12 +181,12 @@ _user_management() { if useradd -R "${_DESTDIR}" ${_ADMIN_ATTR} -c "${_FN}" -m "${_USER}" &>"${_LOG}"; then _set_password _dialog --title " Success " --no-mouse --infobox "User Account ${_USER} created succesfully." 3 50 - read -r -t 2 + sleep 2 _NEXTITEM=2 break else _dialog --title " ERROR " --no-mouse --infobox "User creation failed! Please try again." 3 50 - read -r -t 3 + sleep 3 fi fi done ;; @@ -232,11 +232,11 @@ _user_management() { if [[ -n "${_ADMIN_ATTR}" ]]; then usermod -R "${_DESTDIR}" -rG wheel "${_USER}" _dialog --title " Success " --no-mouse --infobox "User ${_USER} removed as Administrator and removed from wheel group." 3 70 - read -r -t 2 + sleep 2 else usermod -R "${_DESTDIR}" -aG wheel "${_USER}" _dialog --title " Success " --no-mouse --infobox "User ${_USER} switched to Administrator and added to wheel group." 3 70 - read -r -t 2 + sleep 2 fi ;; "2") _NEXTITEM=2 if _prepare_password User; then @@ -246,14 +246,14 @@ _user_management() { if _set_comment; then usermod -R "${_DESTDIR}" -c "${_FN}" "${_USER}" _dialog --title " Success " --no-mouse --infobox "New comment set for ${_USER}." 3 50 - read -r -t 2 + sleep 2 fi ;; "4") if _NEXTITEM=4 _dialog --defaultno --yesno \ "${_USER} will be COMPLETELY ERASED!\nALL USER DATA OF ${_USER} WILL BE LOST.\n\nAre you absolutely sure?" 0 0 && \ userdel -R "${_DESTDIR}" -r "${_USER}" &>"${_LOG}"; then _dialog --title " Success " --no-mouse --infobox "User ${_USER} deleted succesfully." 3 50 - read -r -t 3 + sleep 3 break fi ;; *) break ;; diff --git a/usr/lib/archboot/installer/mountpoints.sh b/usr/lib/archboot/installer/mountpoints.sh index 3ffbea11b..b660a9d51 100644 --- a/usr/lib/archboot/installer/mountpoints.sh +++ b/usr/lib/archboot/installer/mountpoints.sh @@ -172,11 +172,11 @@ _run_mkfs() { else _mkfs "${_DEV}" "${_FSTYPE}" "${_DESTDIR}" "${_DOMKFS}" "${_MP}" "${_LABEL_NAME}" "${_FS_OPTIONS}" || return 1 fi - read -r -t 1 + sleep 1 _COUNT=$((_COUNT+_PROGRESS_COUNT)) done < /tmp/.parts _progress "100" "Mountpoints finished successfully." - read -r -t 2 + sleep 2 } _create_filesystem() { @@ -194,7 +194,7 @@ _create_filesystem() { _LABEL_NAME=$(cat "${_ANSWER}") if rg "|${_LABEL_NAME}$" /tmp/.parts; then _dialog --title " ERROR " --no-mouse --infobox "You have defined 2 identical LABEL names! Please enter another name." 3 60 - read -r -t 5 + sleep 5 _LABEL_NAME="" fi done @@ -309,7 +309,7 @@ _mountpoints() { if ! [[ "${_DEV}" == "> NONE" || "${_DEV}" == "> FILE" ]]; then if ! [[ "${_FSTYPE}" == "swap" ]]; then _dialog --title " ERROR " --no-mouse --infobox "SWAP PARTITION has not a swap filesystem." 3 60 - read -r -t 5 + sleep 5 _MP_DONE="" else _MP_DONE=1 @@ -320,11 +320,11 @@ _mountpoints() { elif [[ -z "${_ROOT_DONE}" ]]; then if [[ "${_FSTYPE}" == "vfat" ]]; then _dialog --title " ERROR " --no-mouse --infobox "ROOT DEVICE has a vfat filesystem." 3 60 - read -r -t 5 + sleep 5 _MP_DONE="" elif [[ "${_FSTYPE}" == "swap" ]]; then _dialog --title " ERROR " --no-mouse --infobox "ROOT DEVICE has a swap filesystem." 3 60 - read -r -t 5 + sleep 5 _MP_DONE="" else _MP_DONE=1 @@ -332,7 +332,7 @@ _mountpoints() { elif [[ -z "${_UEFISYSDEV_DONE}" ]]; then if ! [[ "${_FSTYPE}" == "vfat" ]]; then _dialog --title " ERROR " --no-mouse --infobox "EFI SYSTEM PARTITION has not a vfat filesystem." 3 60 - read -r -t 5 + sleep 5 _MP_DONE="" else _MP_DONE=1 @@ -340,7 +340,7 @@ _mountpoints() { elif [[ -n "${_XBOOTLDR}" ]]; then if ! [[ "${_FSTYPE}" == "vfat" ]]; then _dialog --title " ERROR " --no-mouse --infobox "EXTENDED BOOT LOADER PARTITION has not a vfat filesystem." 3 70 - read -r -t 5 + sleep 5 _MP_DONE="" else _MP_DONE=1 @@ -463,7 +463,7 @@ _mkfs() { #shellcheck disable=SC2181 if [[ -f "/tmp/.mp-error" ]]; then _progress "100" "ERROR: Creating swap ${1}" - read -r -t 5 + sleep 5 return 1 fi fi @@ -474,7 +474,7 @@ _mkfs() { fi if [[ -f "/tmp/.mp-error" ]]; then _progress "100" "ERROR: Activating swap ${1}" - read -r -t 5 + sleep 5 return 1 fi else @@ -491,16 +491,16 @@ _mkfs() { esac if [[ -f "/tmp/.mp-error" ]]; then _progress "100" "ERROR: Creating filesystem ${2} on ${1}" 0 0 - read -r -t 5 + sleep 5 return 1 fi - read -r -t 2 + sleep 2 fi if [[ "${2}" == "btrfs" && -n "${10}" ]]; then _create_btrfs_subvolume fi _btrfs_scan - read -r -t 2 + sleep 2 # create our mount directory mkdir -p "${3}""${5}" # add ssd optimization before mounting @@ -516,7 +516,7 @@ _mkfs() { #shellcheck disable=SC2181 if [[ -f "/tmp/.mp-error" ]]; then _progress "100" "ERROR: Mounting ${3}${5}" - read -r -t 5 + sleep 5 return 1 fi # create /EFI directory on ESP @@ -529,7 +529,7 @@ _mkfs() { # check if /boot exists on ROOT DEVICE if [[ -z "${_CREATE_MOUNTPOINTS}" && "${5}" = "/" && ! -d "${3}${5}/boot" ]]; then _progress "100" "ERROR: ROOT DEVICE ${3}${5} does not contain /boot directory." - read -r -t 5 + sleep 5 _umountall : > /tmp/.mp-error return 1 @@ -537,7 +537,7 @@ _mkfs() { # check on /EFI on /efi mountpoint if [[ -z "${_CREATE_MOUNTPOINTS}" && "${5}" = "/efi" && ! -d "${3}${5}/EFI" ]]; then _progress "100" "ERROR: EFI SYSTEM PARTITION (ESP) ${3}${5} does not contain /EFI directory." - read -r -t 5 + sleep 5 _umountall : > /tmp/.mp-error return 1 @@ -546,7 +546,7 @@ _mkfs() { if [[ -z "${_CREATE_MOUNTPOINTS}" && "${5}" = "/boot" && -n "${_UEFI_BOOT}" && ! -d "${3}${5}/EFI" ]]; then if ! mountpoint -q "${3}/efi"; then _progress "100" "ERROR: EFI SYSTEM PARTITION (ESP) ${3}${5} does not contain /EFI directory." - read -r -t 5 + sleep 5 _umountall : > /tmp/.mp-error return 1 diff --git a/usr/lib/archboot/installer/pacman.sh b/usr/lib/archboot/installer/pacman.sh index b745d965c..b53570a37 100644 --- a/usr/lib/archboot/installer/pacman.sh +++ b/usr/lib/archboot/installer/pacman.sh @@ -20,10 +20,10 @@ _run_pacman(){ # pacman finished, display scrollable output if [[ -e "/tmp/.pacman-success" ]]; then _progress "100" "Package installation complete." 6 75 - read -r -t 2 + sleep 2 else _progress "100" "Package installation failed." 6 75 - read -r -t 2 + sleep 2 fi # ensure the disk is synced sync diff --git a/usr/lib/archboot/installer/quicksetup.sh b/usr/lib/archboot/installer/quicksetup.sh index 2940e24e2..f33e68976 100644 --- a/usr/lib/archboot/installer/quicksetup.sh +++ b/usr/lib/archboot/installer/quicksetup.sh @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-3.0-or-later # created by Tobias Powalowski _auto_partition() { - read -r -t 2 + sleep 2 _progress "10" "Cleaning ${_DISK}..." _clean_disk "${_DISK}" # we assume a /dev/sdX,/dev/vdX or /dev/nvmeXnY format @@ -56,7 +56,7 @@ _auto_partition() { fi fi _progress "100" "Partitions created successfully." - read -r -t 2 + sleep 2 } _auto_create_filesystems() { @@ -98,7 +98,7 @@ _auto_create_filesystems() { else _mkfs "${_DEV}" "${_FSTYPE}" "${_DESTDIR}" "${_DOMKFS}" "${_MP}" "${_LABEL_NAME}" "${_FS_OPTIONS}" || return 1 fi - read -r -t 1 + sleep 1 # set default subvolume for systemd-gpt-autogenerator if [[ "${_FSTYPE}" == "btrfs" ]]; then btrfs subvolume set-default "${_DESTDIR}"/"${_MP}" || return 1 @@ -106,7 +106,7 @@ _auto_create_filesystems() { _COUNT=$((_COUNT+_PROGRESS_COUNT)) done _progress "100" "Filesystems created successfully." - read -r -t 2 + sleep 2 } _autoprepare() { # check on special devices and stop them, else weird things can happen during partitioning! @@ -178,11 +178,11 @@ _autoprepare() { _UEFISYSDEV_SIZE="$(cat "${_ANSWER}")" if [[ -z "${_UEFISYSDEV_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_UEFISYSDEV_SIZE}" -ge "${_DISK_SIZE}" || "${_UEFISYSDEV_SIZE}" -lt "260" || "${_UEFISYSDEV_SIZE}" == "${_DISK_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else _BOOTDEV_SET=1 _UEFISYSDEV_SET=1 @@ -197,11 +197,11 @@ _autoprepare() { _UEFISYSDEV_SIZE="$(cat "${_ANSWER}")" if [[ -z "${_UEFISYSDEV_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_UEFISYSDEV_SIZE}" -ge "${_DISK_SIZE}" || "${_UEFISYSDEV_SIZE}" -lt "260" || "${_UEFISYSDEV_SIZE}" == "${_DISK_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else _UEFISYSDEV_SET=1 _UEFISYSDEV_NUM="$((_DEV_NUM+1))" @@ -216,7 +216,7 @@ _autoprepare() { _BOOTDEV_SIZE="$(cat "${_ANSWER}")" if [[ -z "${_BOOTDEV_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_BOOTDEV_SIZE}" -ge "${_DISK_SIZE}" || "${_BOOTDEV_SIZE}" -lt "100" || "${_BOOTDEV_SIZE}" == "${_DISK_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 @@ -234,11 +234,11 @@ _autoprepare() { _BOOTDEV_SIZE="$(cat "${_ANSWER}")" if [[ -z "${_BOOTDEV_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_BOOTDEV_SIZE}" -ge "${_DISK_SIZE}" || "${_BOOTDEV_SIZE}" -lt "100" || "${_BOOTDEV_SIZE}" == "${_DISK_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else _BOOTDEV_SET=1 _BOOTDEV_NUM=$((_DEV_NUM+1)) @@ -255,11 +255,11 @@ _autoprepare() { _SWAPDEV_SIZE=$(cat "${_ANSWER}") if [[ -z "${_SWAPDEV_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_SWAPDEV_SIZE}" -ge "${_DISK_SIZE}" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a too large size, please enter again." 3 60 - read -r -t 5 + sleep 5 elif [[ "${_SWAPDEV_SIZE}" == "0" ]]; then _SWAPDEV_SET=1 _SKIP_SWAP=1 @@ -295,11 +295,11 @@ _autoprepare() { else if [[ -z "${_ROOTDEV_SIZE}" || "${_ROOTDEV_SIZE}" == 0 || "${_ROOTDEV_SIZE}" -lt "2000" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered an invalid size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if [[ "${_ROOTDEV_SIZE}" -ge "${_DISK_SIZE}" || "$((_DISK_SIZE-_ROOTDEV_SIZE))" -lt "350" ]]; then _dialog --title " ERROR " --no-mouse --infobox "You have entered a too large size, please enter again." 3 60 - read -r -t 5 + sleep 5 else if _dialog --title " Confirmation " --yesno "$((_DISK_SIZE-_ROOTDEV_SIZE))M will be used for your /home completely?" 5 65; then _ROOTDEV_SET=1 @@ -341,6 +341,6 @@ _autoprepare() { fi _auto_create_filesystems | _dialog --title " Filesystems " --no-mouse --gauge "Creating Filesystems on ${_DISK}..." 6 75 0 _dialog --title " Success " --no-mouse --infobox "Quick Setup was successful." 3 40 - read -r -t 3 + sleep 3 } # vim: set ft=sh ts=4 sw=4 et: