Skip to content

Checkstyle is a development tool to help programmers write Java code that adheres to a coding standard. By default it supports the Google Java Style Guide and Sun Code Conventions, but is highly configurable. It can be invoked with an ANT task and a command line program.

License

LGPL-2.1, Apache-2.0 licenses found

Licenses found

LGPL-2.1
LICENSE
Apache-2.0
LICENSE.apache20
Notifications You must be signed in to change notification settings

ningg/checkstyle

 
 

Repository files navigation

Members chat: Contributors chat:

Checkstyle is a tool for checking Java source code for adherence to a Code Standard or set of validation rules (best practices).

The latest release version can be found at GitHub releases or at Maven repo.

Each-commit builds of maven artifacts can be found at Maven Snapshot repository .

Documentation is available in HTML format, see https://checkstyle.org/checks.html.

Build instructions and Contribution

Build instructions

Setup IDE for development

Explanation on how to create your own module

Verification of code quality

Sending Pull Request

Report Issue

Continuous integration and Quality reports

Travis (Linux & MacOS build): AppVeyor (Windows build):

Quality reports: https://checkstyle.org/project-reports.html

JavaScript, CSS and Java source file analysis on Codacy:

Feedback/Support

Please send any feedback to https://groups.google.com/forum/?hl=en#!forum/checkstyle

Questions and Answers from community:

Bugs and Feature requests (not the questions): https://github.com/checkstyle/checkstyle/issues

Support/Sponsor checkstyle

If you want to speed up fixing of issue and want to encourage somebody in internet to resolve any issue:

Licensing

This software is licensed under the terms in the file named "LICENSE" in this directory.

The software uses the ANTLR package (https://www.antlr.org/). Its license terms are in the file named "RIGHTS.antlr" in this directory.

This product includes software developed by The Apache Software Foundation (http://www.apache.org/).

The software uses the Logging and Beanutils packages from the Apache Commons project (http://commons.apache.org/). The license terms of these packages are in the file named "LICENSE.apache20" in this directory.

The software uses the Google Guava Libraries (https://github.com/google/guava/). The license terms of these packages are in the file named "LICENSE.apache20" in this directory.

The software uses the Picocli Library (https://github.com/remkop/picocli/). Its license terms are in the file named "LICENSE.apache20" in this directory.

NingG 定制 Java Code Style

为了增加代码的「美感」, 进行了 java code style 的部分定制;

因此, 需要同步定制 checkstyle。

具体定制的内容:

原始取值 定制之后 定制时间 备注
Indentation.basicOffset 2 4 20180731 行缩进
Indentation.caseIndent 2 4 20180731 行缩进
Indentation.throwsIndent 4 8 20180731 行缩进
Indentation.lineWrappingIndentation 4 8 20180731 行缩进
Indentation.arrayInitIndent 2 4 20180731 行缩进
LineLength 100 120 20180731 行长度
JavadocParagraph 启用 删除 20180731 JavaDoc 的校验
SummaryJavadoc 启用 删除 20180731 JavaDoc 的校验
VariableDeclarationUsageDistance.allowedDistance 3 10 20180801 变量的声明和使用
LineLength.max 120 180 20180801 单行长度校验

更多细节, 参考: Google's Java Style Checkstyle Coverage

About

Checkstyle is a development tool to help programmers write Java code that adheres to a coding standard. By default it supports the Google Java Style Guide and Sun Code Conventions, but is highly configurable. It can be invoked with an ANT task and a command line program.

Resources

License

LGPL-2.1, Apache-2.0 licenses found

Licenses found

LGPL-2.1
LICENSE
Apache-2.0
LICENSE.apache20

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 97.8%
  • HTML 0.8%
  • Shell 0.7%
  • GAP 0.5%
  • JavaScript 0.1%
  • CSS 0.1%