This is an automated email from the ASF dual-hosted git repository.
jave pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/incubator-dolphinscheduler.git
The following commit(s) were added to refs/heads/dev by this push:
new 42b0d67 add checkstyle job in github action. (#3518)
42b0d67 is described below
commit 42b0d67cef03f2158d6805103789bb139248c70a
Author: Jave-Chen <[email protected]>
AuthorDate: Sun Aug 16 12:37:26 2020 +0800
add checkstyle job in github action. (#3518)
---
.github/workflows/ci_ut.yml | 27 +++++++++++++++++++++++++++
1 file changed, 27 insertions(+)
diff --git a/.github/workflows/ci_ut.yml b/.github/workflows/ci_ut.yml
index 70790a7..739c9be 100644
--- a/.github/workflows/ci_ut.yml
+++ b/.github/workflows/ci_ut.yml
@@ -91,3 +91,30 @@ jobs:
mkdir -p ${LOG_DIR}
docker-compose -f $(pwd)/docker/docker-swarm/docker-compose.yml logs
dolphinscheduler-postgresql > ${LOG_DIR}/db.txt
continue-on-error: true
+
+ Checkstyle:
+ name: Check code style
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ # In the checkout@v2, it doesn't support git submodule. Execute the
commands manually.
+ - name: checkout submodules
+ shell: bash
+ run: |
+ git submodule sync --recursive
+ git -c protocol.version=2 submodule update --init --force
--recursive --depth=1
+ - name: check code style
+ env:
+ WORKDIR: ./
+ REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+ CHECKSTYLE_CONFIG: style/checkstyle.xml
+ REVIEWDOG_VERSION: v0.10.2
+ run: |
+ wget -O - -q
https://github.com/checkstyle/checkstyle/releases/download/checkstyle-8.22/checkstyle-8.22-all.jar
> /opt/checkstyle.jar
+ wget -O - -q
https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh | sh -s
-- -b /opt ${REVIEWDOG_VERSION}
+ java -jar /opt/checkstyle.jar "${WORKDIR}" -c "${CHECKSTYLE_CONFIG}"
-f xml \
+ | /opt/reviewdog -f=checkstyle \
+ -reporter="${INPUT_REPORTER:-github-pr-check}" \
+ -filter-mode="${INPUT_FILTER_MODE:-added}" \
+ -fail-on-error="${INPUT_FAIL_ON_ERROR:-false}"
\ No newline at end of file