[ofbiz-framework] branch trunk updated: Improved: Updated checkstyle.xml with allowSingleLineStatement as true, this brings down checkstyle maxErrors to 20037.(-625). (OFBIZ-11886) Thanks Jacques for your suggestions and comments.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated: Improved: Updated checkstyle.xml with allowSingleLineStatement as true, this brings down checkstyle maxErrors to 20037.(-625). (OFBIZ-11886) Thanks Jacques for your suggestions and comments.

surajk
This is an automated email from the ASF dual-hosted git repository.

surajk pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new afa98bb  Improved: Updated checkstyle.xml with allowSingleLineStatement as true, this brings down checkstyle maxErrors to 20037.(-625). (OFBIZ-11886) Thanks Jacques for your suggestions and comments.
afa98bb is described below

commit afa98bb8a6665484dd4f20815e20cb1b12b6a9d7
Author: Suraj Khurana <[hidden email]>
AuthorDate: Tue Jul 21 12:44:20 2020 +0530

    Improved: Updated checkstyle.xml with allowSingleLineStatement as true, this brings down checkstyle maxErrors to 20037.(-625).
    (OFBIZ-11886)
    Thanks Jacques for your suggestions and comments.
---
 build.gradle                     | 2 +-
 config/checkstyle/checkstyle.xml | 4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/build.gradle b/build.gradle
index 531c0b4..852019c 100644
--- a/build.gradle
+++ b/build.gradle
@@ -287,7 +287,7 @@ checkstyle {
     // the sum of errors found last time it was changed after using the
     // ‘checkstyle’ tool present in the framework and in the official
     // plugins.
-    tasks.checkstyleMain.maxErrors = 20662
+    tasks.checkstyleMain.maxErrors = 20037
     // Currently there are a lot of errors so we need to temporarily
     // hide them to avoid polluting the terminal output.
     showViolations = false
diff --git a/config/checkstyle/checkstyle.xml b/config/checkstyle/checkstyle.xml
index af7b1dc..dd3bdb8 100644
--- a/config/checkstyle/checkstyle.xml
+++ b/config/checkstyle/checkstyle.xml
@@ -98,7 +98,9 @@ under the License.
         <module name="AvoidNestedBlocks"/>
         <module name="EmptyBlock"/>
         <module name="LeftCurly"/>
-        <module name="NeedBraces"/>
+        <module name="NeedBraces">
+            <property name="allowSingleLineStatement" value="true"/>
+        </module>
         <module name="RightCurly"/>
 
         <!-- Checks for common coding problems -->