Fix some read commands
parent
d549dec7bf
commit
23bb16bdc0
|
@ -9,7 +9,7 @@ echo "+===============================+"
|
||||||
#
|
#
|
||||||
|
|
||||||
# Ping my server to check network.
|
# Ping my server to check network.
|
||||||
ping -c 1 kallestruik.nl
|
ping -c 1 kallestruik.nl > /dev/null
|
||||||
|
|
||||||
# Check if the ping was successful. If it was not inform the user and exit.
|
# Check if the ping was successful. If it was not inform the user and exit.
|
||||||
if [ $? != 0 ]; then
|
if [ $? != 0 ]; then
|
||||||
|
@ -51,7 +51,7 @@ else
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Make sure that the user wants to erase the full disk.
|
# Make sure that the user wants to erase the full disk.
|
||||||
read confirmation -p "[!] This will destroy all data on device $disk_base! Are you sure you want to continue? [y/N] "
|
read -p "[!] This will destroy all data on device $disk_base! Are you sure you want to continue? [y/N] " confirmation
|
||||||
|
|
||||||
# If they are not exit.
|
# If they are not exit.
|
||||||
if [ $confirmation != "y" ]; then
|
if [ $confirmation != "y" ]; then
|
||||||
|
@ -59,11 +59,12 @@ else
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
echo "[?] Creating GPT"
|
||||||
# Create a new GPT.
|
# Create a new GPT.
|
||||||
parted $disk_base -- mklabel gpt
|
parted $disk_base -- mklabel gpt
|
||||||
|
|
||||||
# Get the size of swap to use.
|
# Get the size of swap to use.
|
||||||
read swap_size -p "[?] How large do you want your swap to be? [GiB] "
|
read -p "[?] How large do you want your swap to be? [GiB] " swap_size
|
||||||
|
|
||||||
# Create partitions.
|
# Create partitions.
|
||||||
echo "[?] Creating partitions."
|
echo "[?] Creating partitions."
|
||||||
|
@ -81,7 +82,7 @@ else
|
||||||
# Get the partition prefix from the user.
|
# Get the partition prefix from the user.
|
||||||
echo "[?] What prefix should be used for partitions? For HDDs and SATA SSDs this is probably the same as the device you selected earlier."
|
echo "[?] What prefix should be used for partitions? For HDDs and SATA SSDs this is probably the same as the device you selected earlier."
|
||||||
echo "[?] For nvme SSDs it will most likely be something like /dev/nvme0n1p"
|
echo "[?] For nvme SSDs it will most likely be something like /dev/nvme0n1p"
|
||||||
read partition_base -p "[?] "
|
read -p "[?] " partition_base
|
||||||
|
|
||||||
# Create filesystems.
|
# Create filesystems.
|
||||||
echo "[?] Creating file systems. This might take a while."
|
echo "[?] Creating file systems. This might take a while."
|
||||||
|
|
Loading…
Reference in New Issue