File tree Expand file tree Collapse file tree 3 files changed +14
-13
lines changed
Expand file tree Collapse file tree 3 files changed +14
-13
lines changed Original file line number Diff line number Diff line change 1- FROM alpine:3.13
1+ FROM openjdk:8-alpine
22
33ENV REVIEWDOG_VERSION=v0.11.0
44
5+ ENV CHECKSTYLE_VERSION=8.42
6+
57SHELL ["/bin/ash" , "-eo" , "pipefail" , "-c" ]
68
79# hadolint ignore=DL3006
810RUN apk --no-cache add git
911
1012RUN wget -O - -q https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh| sh -s -- -b /usr/local/bin/ ${REVIEWDOG_VERSION}
1113
12- # TODO: Install a linter and/or change docker image as you need.
13- RUN wget -O - -q https://git.io/misspell | sh -s -- -b /usr/local/bin/
14+ RUN wget -O - -q https://github.com/checkstyle/checkstyle/releases/download/checkstyle-${CHECKSTYLE_VERSION}/checkstyle-${CHECKSTYLE_VERSION}-all.jar > /checkstyle.jar
1415
1516COPY entrypoint.sh /entrypoint.sh
1617
Original file line number Diff line number Diff line change 1- name : ' TODO: Run <linter-name> with reviewdog'
2- description : ' TODO: 🐶 Run <linter-name> with reviewdog on pull requests to improve code review experience.'
3- author : ' TODO: <your-name> '
1+ name : ' Run checkstyle (Code Standard) with reviewdog'
2+ description : ' 🐶 Run checkstyle with reviewdog on pull requests to improve code review experience.'
3+ author : ' luiszimmermann '
44inputs :
55 github_token :
66 description : ' GITHUB_TOKEN'
@@ -28,10 +28,10 @@ inputs:
2828 reviewdog_flags :
2929 description : ' Additional reviewdog flags'
3030 default : ' '
31- # ## Flags for <linter-name> ###
32- locale :
33- description : ' -locale flag of misspell. (US/UK) '
34- default : ' '
31+ # ## Parameters for checkstyle ###
32+ configuration_file :
33+ description : ' -c parameter. Specifies the location of the file that defines the configuration modules. '
34+ default : ' google_checks.xml '
3535runs :
3636 using : ' docker'
3737 image : ' Dockerfile'
Original file line number Diff line number Diff line change 77
88export REVIEWDOG_GITHUB_API_TOKEN=" ${INPUT_GITHUB_TOKEN} "
99
10- misspell -locale= " ${INPUT_LOCALE }" . \
11- | reviewdog -efm= " %f:%l:%c: %m " \
12- -name=" linter-name (misspell) " \
10+ exec java -jar /checkstyle.jar " . " -c " ${INPUT_CONFIGURATION_FILE }" -f xml \
11+ | reviewdog -f=checkstyle \
12+ -name=" checkstyle " \
1313 -reporter=" ${INPUT_REPORTER:- github-pr-check} " \
1414 -filter-mode=" ${INPUT_FILTER_MODE} " \
1515 -fail-on-error=" ${INPUT_FAIL_ON_ERROR} " \
You can’t perform that action at this time.
0 commit comments