From 97e5072d9f322870381346c895b69b282b837c2f Mon Sep 17 00:00:00 2001 From: Howard Wu <40033067+Howard20181@users.noreply.github.com> Date: Fri, 23 Sep 2022 16:43:50 +0800 Subject: [PATCH] Minor Fixes --- scripts/build.sh | 2 +- scripts/run.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/build.sh b/scripts/build.sh index eaf2a8f..8e0774d 100755 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -281,7 +281,7 @@ fi require_su() { if test "$(whoami)" != "root"; then - if [ -z "$SUDO" ] && [ "$($SUDO whoami)" != "root" ]; then + if [ -z "$SUDO" ] || [ "$($SUDO whoami)" != "root" ]; then echo "ROOT/SUDO is required to run this script" abort fi diff --git a/scripts/run.sh b/scripts/run.sh index e2777b3..3c1c2f8 100755 --- a/scripts/run.sh +++ b/scripts/run.sh @@ -120,7 +120,7 @@ winetricks list-installed | grep -E "^msxml6" >/dev/null 2>&1 || { } WHIPTAIL=$(command -v whiptail 2>/dev/null) DIALOG=$(command -v dialog 2>/dev/null) -DIALOG=${WHIPTAIL:DIALOG} +DIALOG=${WHIPTAIL:-$DIALOG} function Radiolist { declare -A o="$1" shift