From 35b79247d7fa3ecfbc27da6d548c7e026c970fcb Mon Sep 17 00:00:00 2001 From: Hannes Weisbach Date: Sat, 25 Jan 2025 20:07:19 +0100 Subject: [PATCH] Change invocation of mokutil to return 0 on success Some versions of mokutil have an exit code of -1 when invoked without arguments, which causes the check for mokutil to fail and subsequent re-installation of required tools, regardless of whether they are already installed or not. Invoking mokutil with --version also results in an exit code of -1. This seems to have been fixed in (at least) mokutil 0.7.0. --- files/setup/autodesk_fusion_installer_x86-64.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/setup/autodesk_fusion_installer_x86-64.sh b/files/setup/autodesk_fusion_installer_x86-64.sh index 21831e8..cb91788 100755 --- a/files/setup/autodesk_fusion_installer_x86-64.sh +++ b/files/setup/autodesk_fusion_installer_x86-64.sh @@ -143,7 +143,7 @@ check_required_packages() { ;; mokutil) - if ! mokutil &>/dev/null; then + if ! mokutil --list-enrolled &>/dev/null; then echo -e "${RED}The required command (${cmd}) is not available!${NOCOLOR}" MISSING_COMMANDS+=("$cmd") else