android-check-2


Source link: https://github.com/stoyicker/android-check-2

Android Check 2

Static code analysis plugin for Android projects. This is a fork of the original android-check plugin, which implements a really useful concept, but unfortunately seems abandoned.

Who uses this?

Build status

master

dev

Usage

This plugin is available in the Gradle Plugin Portal and jCenter. It attaches itself to the check task if it finds it (that is, you don't use the plugins block and you apply either the application or library Android plugins first) - otherwise you'll need to execute the corresponding tasks manually when desired: androidCheckstyle for CheckStyle, and androidPmd for PMD.

Configuration

Recommended

The default one.

Customized

// Configuration is completely optional, defaults will be used if not present check {

// Do absolutely nothing, default: false
skip true/false
// Fails build if a violation is found, default: true
abortOnError true/false. Ignored if all per-tool confs are set to abortOnError false (see below)
// Checkstyle configuration
checkstyle {

  // Completely skip CheckStyle, default: false
  skip true/false

// Fails build if CheckStyle rule violation is found, default: false
  abortOnError true/false

// Configuration file for CheckStyle, default: <project_path>/config/checkstyle.xml, if non-existent then <project_path>/<module_path>/config/checkstyle.xml, if non-existent then plugin/src/main/resources/checkstyle/conf-default.xml
  config 'path/to/checkstyle.xml'

// Output file for XML reports, default: new File(project.buildDir, 'outputs/checkstyle/checkstyle.xml')
  reportXML new File(project.buildDir, 'path/where/you/want/checkstyle.xml')

// Output file for HTML reports, default: new File(project.buildDir, 'outputs/checkstyle/checkstyle.html')
  reportHTML new File(project.buildDir, 'path/where/you/want/checkstyle.html')

}

// PMD configuration
pmd {

  // Same options as Checkstyle, except for a couple of defaults:

// Configuration file for CheckStyle, default: <project_path>/config/pmd.xml, if non-existent then <project_path>/<module_path>/config/pmd.xml, if non-existent then plugin/src/main/resources/pmd/conf-default.xml
  config 'path/to/pmd.xml'

// Output file for XML reports, default: new File(project.buildDir, 'outputs/pmd/pmd.xml')
  reportXML new File(project.buildDir, 'path/where/you/want/pmd.xml')

 // Output file for HTML reports, default: new File(project.buildDir, 'outputs/pmd/pmd.html')
  reportHTML new File(project.buildDir, 'path/where/you/want/pmd.html')

}
 
}

Also, if abortOnError is true, the browser will open the report for the tool that caused the failure (if your system supports it).

Developed By

The original version of this plugin was developed by:

This fork is owned and maintained by Jorge Antonio Diaz-Benito Soriano.

License

See LICENSE.txt.

Original work licensed under MIT license.

Resources

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes