Skip to content

Commit

Permalink
efm opt using array
Browse files Browse the repository at this point in the history
  • Loading branch information
tsuyoshicho committed Mar 4, 2023
1 parent db8b72a commit f5eb967
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,15 @@ mypy_check_output="$(mypy --show-column-numbers \
"${INPUT_TARGET:-.}" 2>&1 \
)" || mypy_exit_val="$?"

IGNORE_NOTE_EFM_OPTION=""
IGNORE_NOTE_EFM_OPTION=()
if [[ "${INPUT_IGNORE_NOTE}" == "true" ]] ; then
# note ignore
IGNORE_NOTE_EFM_OPTION="-efm=\"%-G%f:%l:%c: note: %m\""
IGNORE_NOTE_EFM_OPTION=(-efm=\"%-G%f:%l:%c: note: %m\")
fi

# shellcheck disable=SC2086
echo "${mypy_check_output}" | reviewdog \
${IGNORE_NOTE_EFM_OPTION} \
"${IGNORE_NOTE_EFM_OPTION[@]}" \
-efm="%f:%l:%c: %t%*[^:]: %m" \
-efm="%f:%l: %t%*[^:]: %m" \
-efm="%f: %t%*[^:]: %m" \
Expand Down

0 comments on commit f5eb967

Please sign in to comment.