fix(script): Count number of file systems, not number of dirs

This commit is contained in:
hygienic-books 2023-10-26 02:20:51 +02:00
parent f83d93a85e
commit 1c1c52c958

View File

@ -8,7 +8,7 @@ boot_disk="$(findmnt --noheadings --target "${boot_dir}" --output 'SOURCE')" ||
'Cowardly exiting. No syslinux files nor MBR were overwritten.'
exit 1
}
if [[ "$(<<<"${boot_dir}" wc -l)" -gt '1' ]]; then
if [[ "$(<<<"${boot_fs}" wc -l)" -gt '1' ]]; then
printf -- '%s\n' \
'More than one drive mounted at '"'${boot_dir}'"' boot dir.' \
'Cowardly exiting. No syslinux files nor MBR were overwritten.'