Skip to content

panchenko/checkstyle-android

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

checkstyle-android

A gradle checkstyle configuration that most closely matches the Android Code Style Guidelines for Contributors. Many Android projects chose to follow those guidelines and this checkstyle configuration helps enforce them on your code.

This is still Work-In-Progress! Only a few rules have been implemented so far. Check the #Contributing section below on how to contrbute ;)

Usage

You can just grab the rules file and use it with your own checkstyle setup or you can add this repo as a git submodule:

git submodule add git@github.com:hypest/checkstyle-android.git

Add it in your project's build.gradle like this:

apply from: 'checkstyle-android/checkstyle.gradle

You can now run the checks at the command line:

./gradlew checkstyle

Xml and html reports will be created in <project build dir>/reports/checkstyle/

You may opt to have the build fail if checkstyle reports issues. You can enable that by adding to build.gradle:

preBuild.dependsOn('checkstyle')

Prerequisities

You will need gradle or AndroidStudio.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct and how you can contribute to this project!

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

Checkstyle config to match the Android code style guidelines

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • XSLT 100.0%