Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace deprecated fail-on-error flag with fail-level #3

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ code review experience.
Optional. Report level for reviewdog [`info`, `warning`, `error`].
The default is `error`.

### `fail_on_error`
### `fail_level`

Optional. Exit code 1 for reviewdog if it finds errors [`true`, `false`].
The default is `false`.
Optional. Exit code 1 for reviewdog if it finds at least 1 issue with severity greater than or equal to the given level [`none`, `any`, `info`, `warning`, `error`].
The default is `none`.

### `reporter`

Expand Down
10 changes: 6 additions & 4 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@ inputs:
level:
description: 'Report level for reviewdog [info,warning,error]'
default: 'error'
fail_on_error:
description: 'Exit code 1 for reviewdog if it finds errors [true,false]'
default: 'false'
fail_level:
description: |
Exit code 1 for reviewdog if it finds at least 1 issue with severity greater than or equal to the given level [none,any,info,warning,error].
Default is none.
default: 'none'
reporter:
description: |
Reporter of reviewdog command [github-pr-check,github-check,github-pr-review].
Expand All @@ -32,7 +34,7 @@ runs:
env:
INPUT_GITHUB_TOKEN: ${{ inputs.github_token }}
INPUT_LEVEL: ${{ inputs.level }}
INPUT_FAIL_ON_ERROR: ${{ inputs.fail_on_error }}
INPUT_FAIL_LEVEL: ${{ inputs.fail_level }}
INPUT_REPORTER: ${{ inputs.reporter }}
INPUT_FILTER_MODE: ${{ inputs.filter_mode }}
INPUT_USE_BUNDLER: ${{ inputs.use_bundler }}
Expand Down
2 changes: 1 addition & 1 deletion script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ ${BUNDLE_EXEC}erblint --lint-all --format compact \
-reporter="${INPUT_REPORTER}" \
-filter-mode="${INPUT_FILTER_MODE}" \
-level="${INPUT_LEVEL}" \
-fail-on-error="${INPUT_FAIL_ON_ERROR}"
-fail-level="${INPUT_FAIL_LEVEL}"
echo '::endgroup::'