From 7be82c71661b3e74e0cb7eb60c0bf8637c27b474 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5kon=20L=C3=B8vdal?= Date: Thu, 15 Sep 2022 12:35:07 +0200 Subject: [PATCH] Fix shellcheck warnings --- env.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/env.md b/env.md index 3b927a0..303656e 100644 --- a/env.md +++ b/env.md @@ -27,7 +27,7 @@ Example of using environment variables in a build script named `run-lint.sh`: ```shell #!/bin/sh -if [ ${GIT_TEST_VERBOSITY:-0} -ge 1 ] +if [ "${GIT_TEST_VERBOSITY:-0}" -ge 1 ] then if [ -f tslint.json ] then @@ -37,9 +37,9 @@ then fi fi -PARENT=`git log --pretty=%P -n 1 HEAD` +PARENT=$(git log --pretty=%P -n 1 HEAD) # If current commit is not a merge commit ... -if [ `echo $PARENT | wc -w` -eq 1 ] +if [ "$(echo "$PARENT" | wc -w)" -eq 1 ] then if [ "$GIT_TEST_PREVIOUS_CHECKED_OUT_COMMIT" = "$PARENT" ] then