From a8bf624bb49e9e91d495d3be19bd377218ef251b Mon Sep 17 00:00:00 2001 From: Clayton Craft Date: Sun, 20 Aug 2023 14:28:36 -0700 Subject: [PATCH] ci/shellcheck: ignore SC3043 warnings about use of 'local' (MR 4340) This configures shellcheck in CI to ignore the use of the 'local'. Using 'local' to support variable scoping can prevent a lot of nasty bugs in shell scripts. Ash supports 'local', even though it's not a POSIX sh thing. It's used extensively in our init.sh script, and many Alpine scripts use it. --- .ci/shellcheck.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.ci/shellcheck.sh b/.ci/shellcheck.sh index 9aaf4fe99..c7ec204a2 100755 --- a/.ci/shellcheck.sh +++ b/.ci/shellcheck.sh @@ -48,5 +48,5 @@ sh_files=" for file in $sh_files; do echo "Test with shellcheck: $file" cd "$DIR/$(dirname "$file")" - shellcheck -e SC1008 -x "$(basename "$file")" + shellcheck -e SC1008 -e SC3043 -x "$(basename "$file")" done