自 SonarQube 5.2 以来,批处理端不再支持任务

Tasks are no more supported on batch side since SonarQube 5.2

我安装了 SonarQube 5.2 和 Sonar-运行ner 2.4(最新版本)。我设法启动了 SonarQube,但在尝试 运行 Sonar-运行ner:

时出现以下错误
ERROR: Unable to execute Sonar
ERROR: Caused by: Tasks are no more supported on batch side since SonarQube 5.2
ERROR:

编辑: 当我使用 --debug

运行 命令时抛出以下异常
ERROR: Error during Sonar runner execution
org.sonar.runner.impl.RunnerException: Unable to execute Sonar
    at org.sonar.runner.impl.BatchLauncher.delegateExecution(BatchLauncher.java:91)
    at org.sonar.runner.impl.BatchLauncher.run(BatchLauncher.java:75)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69)
    at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50)
    at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:102)
    at org.sonar.runner.api.Runner.execute(Runner.java:100)
    at org.sonar.runner.Main.executeTask(Main.java:70)
    at org.sonar.runner.Main.execute(Main.java:59)
    at org.sonar.runner.Main.main(Main.java:53)
Caused by: Tasks are no more supported on batch side since SonarQube 5.2

是否需要更改任何配置才能分析项目?

谢谢

您必须从 项目基目录执行sonar-runner 。所以

cd my/project/base/dir
sonar-runner

编辑

sonar-runner 的基本假设是您在 您希望它完成工作的目录中调用它。它所采用的唯一参数*是要执行的 "tasks",但不再支持这些参数。

*请注意,您可以定义 (-D) 参数以在命令行分析期间使用。