disko: don't fail in flake mode

This commit is contained in:
lassulus 2022-11-09 16:39:15 +01:00
parent 45ef21831e
commit 7e52500078

2
disko
View file

@ -78,7 +78,7 @@ if ! ([[ $mode = "create" ]] || [[ $mode = "mount" ]]); then
abort "mode must be either create or mount"
fi
if [[ -e "${disko_config}" ]]; then
if [[ -e "${disko_config+x}" ]]; then
nix_args+=("--arg" "diskoFile" "$disko_config")
elif [[ -n "${from_flake+x}" ]]; then
nix_args+=("--argstr" "diskoFile" "$disko_config")