From b9b30a577329bc7c4e41e1c011d05930105f8d43 Mon Sep 17 00:00:00 2001 From: Rokoucha Date: Sat, 16 Sep 2023 11:05:39 +0900 Subject: [PATCH] Remove quote around $INPUT_PRETTIER_FLAGS to pass flags correctly --- script.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/script.sh b/script.sh index 69952cc..ef38eec 100755 --- a/script.sh +++ b/script.sh @@ -24,7 +24,8 @@ export REVIEWDOG_GITHUB_API_TOKEN="${INPUT_GITHUB_TOKEN}" # if reporter is github-pr-review, run prettier in write mode and report code suggestions if [ "$INPUT_REPORTER" = "github-pr-review" ]; then - "$(npm root)"/.bin/prettier --write "${INPUT_PRETTIER_FLAGS}" 2>&1 \ + # shellcheck disable=SC2086 + "$(npm root)"/.bin/prettier --write ${INPUT_PRETTIER_FLAGS} 2>&1 \ | reviewdog \ -efm="%E[%trror] %f: %m (%l:%c)" \ -efm="%C[error]%r" \ @@ -40,7 +41,7 @@ if [ "$INPUT_REPORTER" = "github-pr-review" ]; then else # shellcheck disable=SC2086 - "$(npm root)"/.bin/prettier --check "${INPUT_PRETTIER_FLAGS}" 2>&1 | sed --regexp-extended 's/(\[warn\].*)$/\1 File is not properly formatted./' \ + "$(npm root)"/.bin/prettier --check ${INPUT_PRETTIER_FLAGS} 2>&1 | sed --regexp-extended 's/(\[warn\].*)$/\1 File is not properly formatted./' \ | reviewdog \ -efm="%-G[warn] Code style issues found in the above file(s). Forgot to run Prettier%. File is not properly formatted." \ -efm="[%tarn] %f %m" \