From bf8d488eb9d62ab1fc25712d1f3d6bf14bdfc507 Mon Sep 17 00:00:00 2001 From: AuxXxilium Date: Sat, 26 Oct 2024 12:41:02 +0200 Subject: [PATCH] arc: fix config restore Signed-off-by: AuxXxilium --- files/initrd/opt/arc/arc-functions.sh | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/files/initrd/opt/arc/arc-functions.sh b/files/initrd/opt/arc/arc-functions.sh index 39e71c0e..5a0e5273 100755 --- a/files/initrd/opt/arc/arc-functions.sh +++ b/files/initrd/opt/arc/arc-functions.sh @@ -724,7 +724,6 @@ function backupMenu() { fi done if [ -f "${USER_CONFIG_FILE}" ]; then - . ${ARC_PATH}/include/compat.sh PRODUCTVER="$(readConfigKey "productver" "${USER_CONFIG_FILE}")" if [ -n "${PRODUCTVER}" ]; then PLATFORM="$(readConfigKey "platform" "${USER_CONFIG_FILE}")" @@ -732,25 +731,16 @@ function backupMenu() { [ "${PLATFORM}" == "epyc7002" ] && KVERP="${PRODUCTVER}-${KVER}" || KVERP="${KVER}" fi if [ -n "${PLATFORM}" ] && [ -n "${KVERP}" ]; then - updateAddons - [ $? -ne 0 ] && updateFailed || true - updateModules "${PLATFORM}" "${KVERP}" - [ $? -ne 0 ] && updateFailed || true - updateLKMs - [ $? -ne 0 ] && updateFailed || true - updatePatches - [ $? -ne 0 ] && updateFailed || true - KERNEL="$(readConfigKey "kernel" "${USER_CONFIG_FILE}")" - if [ "${KERNEL}" == "custom" ]; then - updateCustom - [ $? -ne 0 ] && updateFailed || true - fi writeConfigKey "modules" "{}" "${USER_CONFIG_FILE}" while read -r ID DESC; do writeConfigKey "modules.${ID}" "" "${USER_CONFIG_FILE}" done < <(getAllModules "${PLATFORM}" "${KVERP}") fi fi + dialog --backtitle "$(backtitle)" --title "Restore Arc Config" \ + --aspect 18 --infobox "Restore successful! -> Reload Arc Init now" 5 50 + sleep 2 + exec init.sh ;; 2) DSMROOTS="$(findDSMRoot)"