From 6a7375dd9bf720715d0eb8c3c880bdba0c1cc80e Mon Sep 17 00:00:00 2001 From: ByteHamster Date: Mon, 30 Mar 2020 01:05:33 +0200 Subject: [PATCH] Added diff-checkstyle --- .circleci/config.yml | 8 ++++++++ ...best-practice.xml => checkstyle-new-code.xml} | 16 +--------------- 2 files changed, 9 insertions(+), 15 deletions(-) rename config/checkstyle/{checkstyle-best-practice.xml => checkstyle-new-code.xml} (93%) diff --git a/.circleci/config.yml b/.circleci/config.yml index b5903350f..ccdd5aaee 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -72,3 +72,11 @@ workflows: - run: name: Checkstyle command: ./gradlew checkstyle + - run: + name: Diff-Checkstyle + command: | + git fetch origin develop + branchBaseCommit=`git merge-base origin/develop HEAD` + echo "Comparing to $branchBaseCommit" + curl -s -L https://github.com/yangziwen/diff-checkstyle/releases/download/0.0.4/diff-checkstyle.jar > diff-checkstyle.jar + java -Dconfig_loc=config/checkstyle -jar diff-checkstyle.jar -c config/checkstyle/checkstyle-new-code.xml --git-dir . --base-rev $branchBaseCommit diff --git a/config/checkstyle/checkstyle-best-practice.xml b/config/checkstyle/checkstyle-new-code.xml similarity index 93% rename from config/checkstyle/checkstyle-best-practice.xml rename to config/checkstyle/checkstyle-new-code.xml index 154d2a896..0076bac23 100644 --- a/config/checkstyle/checkstyle-best-practice.xml +++ b/config/checkstyle/checkstyle-new-code.xml @@ -2,14 +2,9 @@ - - + @@ -219,15 +214,6 @@ - - - - - - - - -