hooks/luks.init: allow word-splitting to remove empty args

Fixes: #25
This commit is contained in:
illiliti 2021-06-24 04:16:27 +03:00
parent 8abfcc9052
commit 93a9cffaf1

View File

@ -11,7 +11,7 @@ mkdir -p /run/cryptsetup
resolve_device "$luks_root" resolve_device "$luks_root"
DM_DISABLE_UDEV=1 cryptsetup open \ DM_DISABLE_UDEV=1 cryptsetup open \
"${luks_discard:+--allow-discards}" \ ${luks_discard:+--allow-discards} \
"${luks_header:+--header=$luks_header}" \ ${luks_header:+--header=$luks_header} \
"${luks_key:+--key-file=$luks_key}" -- "$device" \ ${luks_key:+--key-file=$luks_key} -- "$device" \
"${luks_name:-crypt-${device##*/}}" || panic "failed to unlock LUKS" "${luks_name:-crypt-${device##*/}}" || panic "failed to unlock LUKS"