Skip to content

Commit

Permalink
Checkstyle: force package-info.java for all packages
Browse files Browse the repository at this point in the history
  • Loading branch information
barakugav committed Mar 23, 2024
1 parent 1996446 commit e69930b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
8 changes: 6 additions & 2 deletions ect/checkstyle-suppressions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,18 @@
<!-- Suppress formatting warnings of auto-generated code -->
<suppress files="[\\/]src-generated[\\/]"
checks="(.*Whitespace.*|MethodParamPad|LineLength|LeftCurly|SeparatorWrap)" />
<!-- The generated sources are added to non-generated package in which there is package-info.java -->
<suppress files="[\\/]src-generated[\\/]"
checks="(JavadocPackage)" />


<!-- No need for javadoc for com.jgalgo.internal.** -->
<suppress files="com[\\/]jgalgo[\\/]internal[\\/]"
checks="(MissingJavadocMethod|MissingJavadocType)" />
checks="(MissingJavadocMethod|MissingJavadocType|JavadocPackage)" />

<!-- Benchmarks are not released, suppress a lot of checks -->
<suppress files="com[\\/]jgalgo[\\/]bench[\\/]"
checks="(MissingJavadocMethod|MissingJavadocType|MethodName)" />
checks="(MissingJavadocMethod|MissingJavadocType|MethodName|JavadocPackage)" />
<!-- Completely ignore JMH generated sources -->
<suppress files="[\\/]jmh_generated[\\/]" checks="[a-zA-Z0-9]*" />

Expand Down
4 changes: 4 additions & 0 deletions ect/checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@
<!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
<module name="NewlineAtEndOfFile"/>

<!-- Checks that a package-info.java file exists for each package. -->
<!-- See http://checkstyle.sf.net/config_javadoc.html#JavadocPackage -->
<module name="JavadocPackage"/>

<module name="LineLength">
<property name="fileExtensions" value="java" />
<property name="max" value="120" />
Expand Down

0 comments on commit e69930b

Please sign in to comment.