Last modified: 2014-05-19 15:16:25 UTC
checkstyle[http://checkstyle.sourceforge.net/] is a java code linting utility similar to jshint for JS. Can it run on apps/android/java-mwapi, with the config file the checkstyle.xml in the repo itself, and be made voting?
Change 91767 had a related patch set uploaded by Hashar: contint: add in checkstyle package https://gerrit.wikimedia.org/r/91767
Checkstyle is packaged in Ubuntu Precise, above change would install it on the Jenkins slaves. From there, I have ZERO clue how to run checkstyle myself, if you guys could write down here the commands that need to be run I can then write the basic jenkins job that will make it happen. Jenkins will use a plugin for that https://wiki.jenkins-ci.org/display/JENKINS/Checkstyle+Plugin
Change 91767 abandoned by Hashar: contint: add in checkstyle package Reason: maven handle all of it for us :] https://gerrit.wikimedia.org/r/91767
The package is not needed. One can "just" run: mvn checkstyle:checkstyle
Created attachment 13585 [details] mvn checkstyle:checkstyle failing to produce report I created a Jenkins test job that runs 'mvn checkstyle:checkstyle'. It is based on https://gerrit.wikimedia.org/r/#/c/91770/ which introduce a style issue. The run does complete: [INFO] Starting audit... ../test-checkstyle-maven/src/main/java/org/mediawiki/api/RequestBuilder.java:11: First sentence should end with a period. Audit done. But the report eventually fail. Attached is console output.
Note the: log4j:WARN No appenders could be found for logger (org.apache.commons.beanutils.converters.BooleanConverter). log4j:WARN Please initialize the log4j system properly. The Jenkins page is https://integration.wikimedia.org/ci/job/test-checkstyle-maven/5/ And the japi plugin does have some error reported: Using Jenkins 'checkstyle' plugin: https://integration.wikimedia.org/ci/job/test-checkstyle-maven/5/org.mediawiki$api/ With the Jenkins 'violations' plugin, that is the same: https://integration.wikimedia.org/ci/job/test-checkstyle-maven/6/org.mediawiki$api/console I reproduce the issue on my laptop.
Yuvi is that working for you?