Details
Description
I would like to be able to configure the Web Plugin via a sonar-project.properties file rather than a pom.xml.
Our project doesn't use Maven, so I'd prefer not to create a pom. We only use the standalone runner or the Ant task, and our Java projects are all configured via sonar-project.properties files. I would like to configure web projects that way as well, for consistency and to avoid confusing people.
Currently trying to run sonar-runner with no pom.xml, only a sonar-project.properties, yields the following error:
Exception in thread "main" org.sonar.batch.bootstrapper.BootstrapException: java.lang.NullPointerException at org.sonar.runner.Main.delegateExecution(Main.java:114) at org.sonar.runner.Main.execute(Main.java:67) at org.sonar.runner.Main.main(Main.java:48) Caused by: java.lang.NullPointerException at org.sonar.plugins.web.ProjectConfiguration.configureSourceDir(ProjectConfiguration.java:46) at org.sonar.plugins.web.WebSourceImporter.analyse(WebSourceImporter.java:48) at org.sonar.batch.phases.SensorsExecutor.execute(SensorsExecutor.java:58) at org.sonar.batch.phases.Phases.execute(Phases.java:80) at org.sonar.batch.ProjectBatch.execute(ProjectBatch.java:59) at org.sonar.batch.Batch.analyzeModule(Batch.java:164) at org.sonar.batch.Batch.analyzeModules(Batch.java:82) at org.sonar.batch.Batch.execute(Batch.java:62) at org.sonar.runner.Launcher.executeBatch(Launcher.java:60) at org.sonar.runner.Launcher.execute(Launcher.java:53) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.sonar.runner.Main.delegateExecution(Main.java:111) ... 2 more
Tested WebPlugin 1.1 with standalone runner and the Ant task. Both work fine.