|
I'm experimenting with using Sonar with two different projects. One is a Java-based REST service, and the other is a pure HTML/_javascript_/CSS app. Both projects produce WAR files. The Java project has no relevant issues here. When I try to run the plugin on the pure webapp, it says this:
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.0:sonar (default-cli) on project SunlightGUI-war: Can not execute Sonar: Fail to decorate 'org.sonar.api.resources.Project@2aaec8[id=138,key=SunlightDataService:SunlightGUI-war,qualifier=TRK]': Project "SunlightGUI-war" does not contain any file in its source folders:
The webapp content tree is in src/main/webapp. The _javascript_ source files are in subdirectories of that.
This is the command line I last tried:
mvn sonar:sonar -Dsonar.sources=src/main/webapp,src/main/webapp/js,src/main/webapp/js/mylibs -Dsonar.language=js -Dsonar.binaries=target/SunlightGUI
I tried using the "sonar-runner" tool on this project. With a simple properties file Sonar was able to scan these source files. I'll attach the sonar-project.properties file I used.
|