Had to fix it YET again. I didn't realize that bash had -b to verify if something is a block device

This commit is contained in:
Tristan Ancelet 2023-11-10 16:07:47 -06:00
parent 6da855a05f
commit 2133dd9d47

View File

@ -13,7 +13,7 @@ BOOT_METHOD="${BOOT_METHOD^^}"
}
DISK="${2:?"Disk was not provided"}"
[[ ! -f $DISK ]] && {
[[ ! -b $DISK ]] && {
echo "Your disk ($DISK) does not exist. Please provide a valid one"
exit
}