Remove unbound variables.

This commit is contained in:
dataprolet 2024-05-05 16:55:37 +00:00
parent 3453a0a40e
commit 42314929f5
1 changed files with 15 additions and 5 deletions

View File

@ -9,6 +9,7 @@ exec 2>&1
clear
# Friendly introduction.
echo "0. WELCOME"
echo "Welcome to the Arch Linux installation script!"
echo "This script will ERASE ALL DATA on the partition you will choose next!"
echo
@ -18,7 +19,7 @@ if [[ ! $REPLY =~ ^[Yy]$ ]]
then
exit 1
fi
echo
clear
# Selecting disk.
echo "1. PARTITIONING"
@ -49,11 +50,14 @@ IFS=' '
array=($dev)
dev="${array[0]}"
clear
echo "2. ENCRYPTION"
echo
# Setting encryption password.
echo "Choose a strong password for encrypting the primary partition:"
pwcr=""
while [ -z "$pwcr" ]; do
echo "Please enter a password: "
read -s pwfr
@ -70,7 +74,8 @@ else
echo
fi
done
echo
clear
echo "3. HOSTNAME"
echo
@ -78,13 +83,15 @@ echo
# Setting hostname.
echo "Before installing the system, please enter a hostname:"
read host
echo
clear
echo "4. ROOT PASSWORD"
echo
# Setting root password.
echo "Choose a password for the root account:"
pwr=""
while [ -z "$pwr" ]; do
echo "Please enter a password: "
read -s pwfr
@ -101,7 +108,8 @@ else
echo
fi
done
echo
clear
echo "4. USER"
echo
@ -113,6 +121,7 @@ echo
# Setting user password.
echo "Also please choose a password for your user:"
pwu=""
while [ -z "$pwu" ]; do
echo "Please enter a password: "
read -s pwfr
@ -129,7 +138,8 @@ else
echo
fi
done
echo
clear
echo "5. INSTALLING SYSTEM.."
echo