uses_sd-encrypt was changed to uses_sd_encrypt to make it a valid variable name

This commit is contained in:
Boria138 2023-08-19 15:29:49 +06:00
parent c0396cf28b
commit 9f8b848631
2 changed files with 4 additions and 4 deletions

View File

@ -137,7 +137,7 @@ def get_kernel_params(uuid):
cryptdevice_params = []
have_dracut = libcalamares.utils.target_env_call(["sh", "-c", "which dracut"]) == 0
uses_sd-encrypt = libcalamares.utils.target_env_call(["sh", "-c", "grep -q sd-encrypt /etc/mkinitcpio.conf"])
uses_sd_encrypt = libcalamares.utils.target_env_call(["sh", "-c", "grep -q sd-encrypt /etc/mkinitcpio.conf"])
# Take over swap settings:
# - unencrypted swap partition sets swap_uuid
@ -155,7 +155,7 @@ def get_kernel_params(uuid):
swap_outer_uuid = partition["luksUuid"]
if partition["mountPoint"] == "/" and has_luks:
if have_dracut or uses_sd-encrypt:
if have_dracut or uses_sd_encrypt:
cryptdevice_params = [f"rd.luks.uuid={partition['luksUuid']}"]
else:
cryptdevice_params = [f"cryptdevice=UUID={partition['luksUuid']}:{partition['luksMapperName']}"]

View File

@ -141,7 +141,7 @@ def modify_grub_default(partitions, root_mount_point, distributor):
# Shell exit value 0 means success
have_plymouth = plymouth_bin == 0
have_dracut = dracut_bin == 0
uses_sd-encrypt = mkinitcpio_systemd == 0
uses_sd_encrypt = mkinitcpio_systemd == 0
use_splash = ""
swap_uuid = ""
@ -162,7 +162,7 @@ def modify_grub_default(partitions, root_mount_point, distributor):
cryptdevice_params = []
if have_dracut or used_sd-encrypt:
if have_dracut or used_sd_encrypt:
for partition in partitions:
if partition["fs"] == "linuxswap" and not partition.get("claimed", None):
# Skip foreign swap