From 064f17df2fee0493648cb407770437d14f432c07 Mon Sep 17 00:00:00 2001 From: wileyhy <84648683+wileyhy@users.noreply.github.com> Date: Fri, 28 Apr 2023 13:53:42 -0700 Subject: [PATCH] in two compound `[`'s, replace '-a' with '] && [' Per shellcheck warnings. --- alsa-info/alsa-info.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/alsa-info/alsa-info.sh b/alsa-info/alsa-info.sh index 04d6d17..9b79958 100755 --- a/alsa-info/alsa-info.sh +++ b/alsa-info/alsa-info.sh @@ -47,7 +47,7 @@ update() { SHFILE=$(mktemp -t alsa-info.XXXXXXXXXX) || exit 1 wget -O $SHFILE "https://www.alsa-project.org/alsa-info.sh" >/dev/null 2>&1 REMOTE_VERSION=$(grep SCRIPT_VERSION $SHFILE | head -n1 | sed 's/.*=//') - if [ -s "$SHFILE" -a "$REMOTE_VERSION" != "$SCRIPT_VERSION" ]; then + if [ -s "$SHFILE" ] && [ "$REMOTE_VERSION" != "$SCRIPT_VERSION" ]; then if [[ -n $DIALOG ]] then OVERWRITE= @@ -100,7 +100,7 @@ update() { } cleanup() { - if [ -n "$TEMPDIR" -a "$KEEP_FILES" != "yes" ]; then + if [ -n "$TEMPDIR" ] && [ "$KEEP_FILES" != "yes" ]; then rm -rf "$TEMPDIR" 2>/dev/null fi test -n "$KEEP_OUTPUT" || rm -f "$NFILE"