android - Anrdoid Checkstyle 8.1 error: Unable to create Root Module -


i want write custom check checkstyle. checkstyle work standart modules, when trying run custom module getting error:

failure: build failed exception.  * went wrong: execution failed task ':app:checkstyle'. > unable create root module: config {d:\users\...\config\checkstyle\checkstyle.xml}, classpath {null}.  * try: run --stacktrace option stack trace. run --info or --debug option more log output. 

i use checkstyle gradle plugin here gradle (module: app):

apply plugin: 'com.android.application' apply plugin: "checkstyle"  android {     compilesdkversion 25     buildtoolsversion "25.0.0"     defaultconfig {         applicationid "com.webtrust.tennosushi"         minsdkversion 19         targetsdkversion 25         versioncode 1         versionname "1.0"         testinstrumentationrunner "android.support.test.runner.androidjunitrunner"          multidexenabled true  // line solve problem (Без него вроде как идут ошибки на эмуляторе при испльзовании гугл карт)         aaptoptions.cruncherenabled = false // 2 линии для совместимости с дженкинсом         aaptoptions.usenewcruncher = false     }     buildtypes {         release {             minifyenabled false             proguardfiles getdefaultproguardfile('proguard-android.txt'), 'proguard-rules.pro'         }     }     compileoptions {         sourcecompatibility javaversion.version_1_7     }     configurations.all {         resolutionstrategy.force 'com.google.code.findbugs:jsr305:1.3.9'     } }   // add checkstyle check task. //check.dependson 'checkstyle'  checkstyle {     configfile = new file("${rootproject.rootdir}/config/checkstyle/checkstyle.xml")     toolversion = '8.1' }  task checkstyle(type: checkstyle) {     source 'src'     include '**/*.java'     exclude '**/gen/**'     exclude '**/r.java'     exclude '**/buildconfig.java'      def configprops = ['proj.module.dir': projectdir.absolutepath]     configproperties configprops      // empty classpath     classpath = files() }  prebuild.dependson('checkstyle')  dependencies {     compile filetree(include: ['*.jar'], dir: 'libs')     androidtestcompile('com.android.support.test.espresso:espresso-core:2.2.2', {         exclude group: 'com.android.support', module: 'support-annotations'     })     compile 'com.android.support:appcompat-v7:25.3.0'     compile 'com.android.support.constraint:constraint-layout:1.0.2'     compile 'com.android.support:support-v4:25.3.0'     compile 'com.android.support:design:25.3.0'     compile 'com.android.support:percent:25.3.0'     compile 'com.android.support:gridlayout-v7:25.3.0'     compile 'com.android.support:recyclerview-v7:25.3.0'     compile 'com.android.support:cardview-v7:25.3.0'     compile 'com.google.android.gms:play-services:10.2.6'     compile 'com.google.android.gms:play-services-maps:10.2.6'     compile 'com.github.aakira:expandable-layout:1.6.0@aar'     compile 'co.lujun:androidtagview:1.1.4'     compile 'com.google.code.gson:gson:2.8.1'     testcompile 'junit:junit:4.12'     compile 'com.puppycrawl.tools:checkstyle:8.1' } 

here checkstyle.xml:

<?xml version="1.0" encoding="utf-8"?> <!doctype module public     "-//puppy crawl//dtd check configuration 1.3//en"     "http://www.puppycrawl.com/dtds/configuration_1_3.dtd">  <module name="checker">     <module name="com.apptrust.checkstyle.linesafterclassjavadoccheck"/> </module> 

and custom check:

package com.apptrust.checkstyle;  import com.puppycrawl.tools.checkstyle.api.*;  public class linesafterclassjavadoccheck extends abstractcheck {     private static final int default_lines = 0;     private int max = default_lines;      /**      * returns default token check interested in. used if      * configuration check not define tokens.      *      * @return default tokens      * @see tokentypes      */     @override     public int[] getdefaulttokens() {         return new int[]{tokentypes.block_comment_end};     }      /**      * configurable token set.      * used protect checks against malicious users specify      * unacceptable token set in configuration file.      * default implementation returns check's default tokens.      *      * @return token set check designed for.      * @see tokentypes      */     @override     public int[] getacceptabletokens() {         return new int[0];     }      /**      * called process token.      *      * @param ast token process      */     @override     public void visittoken(detailast ast) {         // find objblock node below class_def         detailast objblock = ast.findfirsttoken(tokentypes.literal_class);         if (ast.getline() != objblock.getline()+1) {             throw new illegalargumentexception("suka bleat");         }     }      /**      * tokens check must registered for.      *      * @return token set must registered for.      * @see tokentypes      */     @override     public int[] getrequiredtokens() {         return new int[0];     } } 

i try use checkstule example of custom check - didn't work too. how cat solve problem? , sorry bad eng.

update: forgon put write stacktrace:

    * exception is:     org.gradle.api.tasks.taskexecutionexception: execution failed task ':app:checkstyle'.         @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeactions(executeactionstaskexecuter.java:84)         @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.execute(executeactionstaskexecuter.java:55)         @ org.gradle.api.internal.tasks.execution.skipuptodatetaskexecuter.execute(skipuptodatetaskexecuter.java:62)         @ org.gradle.api.internal.tasks.execution.validatingtaskexecuter.execute(validatingtaskexecuter.java:58)         @ org.gradle.api.internal.tasks.execution.skipemptysourcefilestaskexecuter.execute(skipemptysourcefilestaskexecuter.java:88)         @ org.gradle.api.internal.tasks.execution.resolvetaskartifactstatetaskexecuter.execute(resolvetaskartifactstatetaskexecuter.java:46)         @ org.gradle.api.internal.tasks.execution.skiptaskwithnoactionsexecuter.execute(skiptaskwithnoactionsexecuter.java:51)         @ org.gradle.api.internal.tasks.execution.skiponlyiftaskexecuter.execute(skiponlyiftaskexecuter.java:54)         @ org.gradle.api.internal.tasks.execution.executeatmostoncetaskexecuter.execute(executeatmostoncetaskexecuter.java:43)         @ org.gradle.api.internal.tasks.execution.catchexceptiontaskexecuter.execute(catchexceptiontaskexecuter.java:34)         @ org.gradle.execution.taskgraph.defaulttaskgraphexecuter$eventfiringtaskworker$1.execute(defaulttaskgraphexecuter.java:236)         @ org.gradle.execution.taskgraph.defaulttaskgraphexecuter$eventfiringtaskworker$1.execute(defaulttaskgraphexecuter.java:228)         @ org.gradle.internal.transformers$4.transform(transformers.java:169)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:106)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:61)         @ org.gradle.execution.taskgraph.defaulttaskgraphexecuter$eventfiringtaskworker.execute(defaulttaskgraphexecuter.java:228)         @ org.gradle.execution.taskgraph.defaulttaskgraphexecuter$eventfiringtaskworker.execute(defaulttaskgraphexecuter.java:215)         @ org.gradle.execution.taskgraph.abstracttaskplanexecutor$taskexecutorworker.processtask(abstracttaskplanexecutor.java:77)         @ org.gradle.execution.taskgraph.abstracttaskplanexecutor$taskexecutorworker.run(abstracttaskplanexecutor.java:58)         @ org.gradle.execution.taskgraph.defaulttaskplanexecutor.process(defaulttaskplanexecutor.java:32)         @ org.gradle.execution.taskgraph.defaulttaskgraphexecuter.execute(defaulttaskgraphexecuter.java:113)         @ org.gradle.execution.selectedtaskexecutionaction.execute(selectedtaskexecutionaction.java:37)         @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:37)         @ org.gradle.execution.defaultbuildexecuter.access$000(defaultbuildexecuter.java:23)         @ org.gradle.execution.defaultbuildexecuter$1.proceed(defaultbuildexecuter.java:43)         @ org.gradle.execution.dryrunbuildexecutionaction.execute(dryrunbuildexecutionaction.java:32)         @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:37)         @ org.gradle.execution.defaultbuildexecuter.execute(defaultbuildexecuter.java:30)         @ org.gradle.initialization.defaultgradlelauncher$3.execute(defaultgradlelauncher.java:196)         @ org.gradle.initialization.defaultgradlelauncher$3.execute(defaultgradlelauncher.java:193)         @ org.gradle.internal.transformers$4.transform(transformers.java:169)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:106)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:56)         @ org.gradle.initialization.defaultgradlelauncher.dobuildstages(defaultgradlelauncher.java:193)         @ org.gradle.initialization.defaultgradlelauncher.dobuild(defaultgradlelauncher.java:119)         @ org.gradle.initialization.defaultgradlelauncher.run(defaultgradlelauncher.java:102)         @ org.gradle.launcher.exec.gradlebuildcontroller.run(gradlebuildcontroller.java:71)         @ org.gradle.tooling.internal.provider.runner.buildmodelactionrunner.run(buildmodelactionrunner.java:50)         @ org.gradle.launcher.exec.chainingbuildactionrunner.run(chainingbuildactionrunner.java:35)         @ org.gradle.tooling.internal.provider.runner.runasbuildoperationbuildactionrunner$1.execute(runasbuildoperationbuildactionrunner.java:43)         @ org.gradle.tooling.internal.provider.runner.runasbuildoperationbuildactionrunner$1.execute(runasbuildoperationbuildactionrunner.java:40)         @ org.gradle.internal.transformers$4.transform(transformers.java:169)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:106)         @ org.gradle.internal.progress.defaultbuildoperationexecutor.run(defaultbuildoperationexecutor.java:56)         @ org.gradle.tooling.internal.provider.runner.runasbuildoperationbuildactionrunner.run(runasbuildoperationbuildactionrunner.java:40)         @ org.gradle.tooling.internal.provider.runner.subscribablebuildactionrunner.run(subscribablebuildactionrunner.java:75)         @ org.gradle.launcher.exec.chainingbuildactionrunner.run(chainingbuildactionrunner.java:35)         @ org.gradle.launcher.exec.inprocessbuildactionexecuter.execute(inprocessbuildactionexecuter.java:41)         @ org.gradle.launcher.exec.inprocessbuildactionexecuter.execute(inprocessbuildactionexecuter.java:26)         @ org.gradle.tooling.internal.provider.continuousbuildactionexecuter.execute(continuousbuildactionexecuter.java:75)         @ org.gradle.tooling.internal.provider.continuousbuildactionexecuter.execute(continuousbuildactionexecuter.java:49)         @ org.gradle.tooling.internal.provider.servicessetupbuildactionexecuter.execute(servicessetupbuildactionexecuter.java:44)         @ org.gradle.tooling.internal.provider.servicessetupbuildactionexecuter.execute(servicessetupbuildactionexecuter.java:29)         @ org.gradle.launcher.daemon.server.exec.executebuild.dobuild(executebuild.java:67)         @ org.gradle.launcher.daemon.server.exec.buildcommandonly.execute(buildcommandonly.java:36)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.watchfordisconnection.execute(watchfordisconnection.java:47)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.resetdeprecationlogger.execute(resetdeprecationlogger.java:26)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.requeststopifsingleuseddaemon.execute(requeststopifsingleuseddaemon.java:34)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.forwardclientinput$2.call(forwardclientinput.java:74)         @ org.gradle.launcher.daemon.server.exec.forwardclientinput$2.call(forwardclientinput.java:72)         @ org.gradle.util.swapper.swap(swapper.java:38)         @ org.gradle.launcher.daemon.server.exec.forwardclientinput.execute(forwardclientinput.java:72)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.logandcheckhealth.execute(logandcheckhealth.java:55)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.logtoclient.dobuild(logtoclient.java:60)         @ org.gradle.launcher.daemon.server.exec.buildcommandonly.execute(buildcommandonly.java:36)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.establishbuildenvironment.dobuild(establishbuildenvironment.java:72)         @ org.gradle.launcher.daemon.server.exec.buildcommandonly.execute(buildcommandonly.java:36)         @ org.gradle.launcher.daemon.server.api.daemoncommandexecution.proceed(daemoncommandexecution.java:120)         @ org.gradle.launcher.daemon.server.exec.startbuildorrespondwithbusy$1.run(startbuildorrespondwithbusy.java:50)         @ org.gradle.launcher.daemon.server.daemonstatecoordinator$1.run(daemonstatecoordinator.java:297)         @ org.gradle.internal.concurrent.executorpolicy$catchandrecordfailures.onexecute(executorpolicy.java:54)         @ org.gradle.internal.concurrent.stoppableexecutorimpl$1.run(stoppableexecutorimpl.java:40)     caused by: : unable create root module: config {d:\users\rares\downloads\tennosushi\config\checkstyle\checkstyle.xml}, classpath {null}.         @ com.puppycrawl.tools.checkstyle.ant.checkstyleanttask.createrootmodule(checkstyleanttask.java:421)         @ com.puppycrawl.tools.checkstyle.ant.checkstyleanttask.realexecute(checkstyleanttask.java:311)         @ com.puppycrawl.tools.checkstyle.ant.checkstyleanttask.execute(checkstyleanttask.java:294)         @ org.apache.tools.ant.unknownelement.execute(unknownelement.java:293)         @ org.apache.tools.ant.dispatch.dispatchutils.execute(dispatchutils.java:106)         @ org.gradle.api.internal.project.ant.basicantbuilder.nodecompleted(basicantbuilder.java:78)         @ org.gradle.internal.metaobject.beandynamicobject$metaclassadapter.invokemethod(beandynamicobject.java:382)         @ org.gradle.internal.metaobject.beandynamicobject.invokemethod(beandynamicobject.java:170)         @ org.gradle.internal.metaobject.abstractdynamicobject.invokemethod(abstractdynamicobject.java:163)         @ org.gradle.api.internal.project.antbuilder.antbuilderdelegate.nodecompleted(antbuilderdelegate.java:118)         @ org.gradle.api.plugins.quality.internal.checkstyleinvoker$_invoke_closure1.docall(checkstyleinvoker.groovy:53)         @ org.gradle.api.internal.closurebackedaction.execute(closurebackedaction.java:70)         @ org.gradle.api.internal.closurebackedaction.execute(closurebackedaction.java:52)         @ org.gradle.api.internal.project.antbuilder.defaultisolatedantbuilder$2.execute(defaultisolatedantbuilder.java:151)         @ org.gradle.api.internal.project.antbuilder.defaultisolatedantbuilder$2.execute(defaultisolatedantbuilder.java:133)         @ org.gradle.api.internal.project.antbuilder.classpathtoclassloadercache.withcachedclassloader(classpathtoclassloadercache.java:134)         @ org.gradle.api.internal.project.antbuilder.defaultisolatedantbuilder.execute(defaultisolatedantbuilder.java:127)         @ org.gradle.api.internal.project.isolatedantbuilder$execute$0.call(unknown source)         @ org.gradle.api.plugins.quality.internal.checkstyleinvoker.invoke(checkstyleinvoker.groovy:46)         @ org.gradle.api.plugins.quality.checkstyle.run(checkstyle.java:141)         @ org.gradle.internal.reflect.javamethod.invoke(javamethod.java:73)         @ org.gradle.api.internal.project.taskfactory.defaulttaskclassinfostore$standardtaskaction.doexecute(defaulttaskclassinfostore.java:141)         @ org.gradle.api.internal.project.taskfactory.defaulttaskclassinfostore$standardtaskaction.execute(defaulttaskclassinfostore.java:134)         @ org.gradle.api.internal.project.taskfactory.defaulttaskclassinfostore$standardtaskaction.execute(defaulttaskclassinfostore.java:123)         @ org.gradle.api.internal.abstracttask$taskactionwrapper.execute(abstracttask.java:632)         @ org.gradle.api.internal.abstracttask$taskactionwrapper.execute(abstracttask.java:615)         @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeaction(executeactionstaskexecuter.java:95)         @ org.gradle.api.internal.tasks.execution.executeactionstaskexecuter.executeactions(executeactionstaskexecuter.java:76)         ... 78 more     caused by: com.puppycrawl.tools.checkstyle.api.checkstyleexception: cannot initialize module com.apptrust.checkstyle.linesafterclassjavadoccheck - unable instantiate 'com.apptrust.checkstyle.linesafterclassjavadoccheck' class, not possible instantiate com.puppycrawl.tools.checkstyle.checks.annotationcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.blockscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.codingcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.designcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.headercom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.importscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.indentationcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.javadoccom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.metricscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.modifiercom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.namingcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.regexpcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.sizescom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.whitespacecom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checkscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.filefilterscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.filterscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.com.apptrust.checkstyle.linesafterclassjavadoccheck, com.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.annotationcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.blockscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.codingcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.designcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.headercom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.importscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.indentationcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.javadoccom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.metricscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.modifiercom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.namingcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.regexpcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.sizescom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.whitespacecom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checkscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.filefilterscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.filterscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.com.apptrust.checkstyle.linesafterclassjavadoccheckcheck. please recheck class name specified canonical name or read how configure short name usage http://checkstyle.sourceforge.net/config.html#packages. please recheck provided classloader checker configured correctly.         @ com.puppycrawl.tools.checkstyle.checker.setupchild(checker.java:461)         @ com.puppycrawl.tools.checkstyle.api.automaticbean.configure(automaticbean.java:171)         @ com.puppycrawl.tools.checkstyle.ant.checkstyleanttask.createrootmodule(checkstyleanttask.java:418)         ... 105 more     caused by: com.puppycrawl.tools.checkstyle.api.checkstyleexception: unable instantiate 'com.apptrust.checkstyle.linesafterclassjavadoccheck' class, not possible instantiate com.puppycrawl.tools.checkstyle.checks.annotationcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.blockscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.codingcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.designcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.headercom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.importscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.indentationcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.javadoccom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.metricscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.modifiercom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.namingcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.regexpcom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.sizescom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checks.whitespacecom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.checkscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.filefilterscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.filterscom.apptrust.checkstyle.linesafterclassjavadoccheck, com.puppycrawl.tools.checkstyle.com.apptrust.checkstyle.linesafterclassjavadoccheck, com.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.annotationcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.blockscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.codingcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.designcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.headercom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.importscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.indentationcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.javadoccom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.metricscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.modifiercom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.namingcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.regexpcom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.sizescom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checks.whitespacecom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.checkscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.filefilterscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.filterscom.apptrust.checkstyle.linesafterclassjavadoccheckcheck, com.puppycrawl.tools.checkstyle.com.apptrust.checkstyle.linesafterclassjavadoccheckcheck. please recheck class name specified canonical name or read how configure short name usage http://checkstyle.sourceforge.net/config.html#packages. please recheck provided classloader checker configured correctly.         @ com.puppycrawl.tools.checkstyle.packageobjectfactory.createmodule(packageobjectfactory.java:184)         @ com.puppycrawl.tools.checkstyle.checker.setupchild(checker.java:451)         ... 107 more 

special @thomasjensen xxx price advice

here good tutorial how use checkstyle gradle, checkstyle version 6.3

here gradle scripts based on tutorial 8.1 checkstyle verison

project build.gradle:

// top-level build file can add configuration options common sub-projects/modules.  buildscript {     repositories {         jcenter()     }     dependencies {         classpath 'com.android.tools.build:gradle:2.3.2'          // note: not place application dependencies here; belong         // in individual module build.gradle files     } }  allprojects {     repositories {         jcenter()     } } 

app module build.gradle

apply plugin: 'com.android.application' apply plugin: 'checkstyle'  android {     compilesdkversion 21     buildtoolsversion '25.0.0'      defaultconfig {         applicationid "com.lsurvila.checkstylebuilder"         minsdkversion 16         targetsdkversion 21         versioncode 1         versionname "1.0"     }     buildtypes {         release {             minifyenabled false             proguardfiles getdefaultproguardfile('proguard-android.txt'), 'proguard-rules.pro'         }     } }  task checkstyle(type: checkstyle) {     configfile = rootproject.file('config/checkstyle/checkstyle.xml')      source 'src/main/java'     include '**/*.java'     exclude '**/gen/**'      // empty classpath     classpath = files() }  dependencies {     compile filetree(dir: 'libs', include: ['*.jar'])     compile 'com.android.support:appcompat-v7:21.0.3'      // testing/creating checkstyle rules     checkstyle project(':custom-checkstyle')      // using compiled version     //checkstyle 'com.puppycrawl.tools:checkstyle:6.3'     //checkstyle files('../config/checkstyle/custom-checkstyle.jar') } 

custom-checkstyle modul build.gradle:

apply plugin: 'java'  jar {     destinationdir rootproject.file('config/checkstyle') }  sourcecompatibility = javaversion.version_1_7 targetcompatibility = javaversion.version_1_7  dependencies {     compile filetree(dir: 'libs', include: ['*.jar'])     compile 'com.puppycrawl.tools:checkstyle:8.1' } 

and screenshoot of project structure: enter image description here

if have checkstyle problem too, please contact me. try because checkstyle setting boring thing


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -