Sonar et projet PHP / Problème avec Maven
Bonjour à tous,
je suis en train d'étudier les différents outils de QA pour PHP, et je suis en ce moment en train d'essayer de tester Sonar pour PHP.
Sonar est déployé sur un serveur Tomcat local, et se lance parfaitement bien.
L'étape suivante, bien entendu, consiste à analyser un projet PHP, et c'est là que les problèmes commencent.
En effet, j'ai bien modifié la config de Maven, et lorsque je tente un mvn sonar:sonar à la racine de mon projet (auquel j'ai ajouté un pom.xml), je me retrouve avec le résultat suivant:
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
| dev@machine:~/path/to/project$ mvn sonar:sonar
[INFO] Scanning for projects...
[INFO] Searching repository for plugin with prefix: 'sonar'.
[INFO] ------------------------------------------------------------------------
[INFO] Building Metafront
[INFO] task-segment: [sonar:sonar] (aggregator-style)
[INFO] ------------------------------------------------------------------------
[INFO] [sonar:sonar {execution: default-cli}]
[INFO] Sonar host: http://localhost:8080/sonar
[INFO] Sonar version: 2.1.2
Downloading: http://[[local_repositories]]/nexus/content/groups/public/org/codehaus/sonar/runtime/sonar-core-maven-plugin/20100531104729/sonar-core-maven-plugin-20100531104729.pom
[INFO] Unable to find resource 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:pom:20100531104729' in repository sonar (http://localhost:8080/sonar/deploy/maven)
Downloading: http://[[local_repositories]]/nexus/content/groups/public/org/codehaus/sonar/runtime/sonar-core-maven-plugin/20100531104729/sonar-core-maven-plugin-20100531104729.pom
[INFO] Unable to find resource 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:pom:20100531104729' in repository central (http://repo1.maven.org/maven2)
Downloading: http://[local_repositories]]/nexus/content/groups/public/org/codehaus/sonar/runtime/sonar-core-maven-plugin/20100531104729/sonar-core-maven-plugin-20100531104729.pom
[INFO] Unable to find resource 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:pom:20100531104729' in repository sonar (http://localhost:8080/sonar/deploy/maven)
Downloading: http://[[local_repositories]]/nexus/content/groups/public/org/codehaus/sonar/runtime/sonar-core-maven-plugin/20100531104729/sonar-core-maven-plugin-20100531104729.pom
[INFO] Unable to find resource 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:pom:20100531104729' in repository central (http://repo1.maven.org/maven2)
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Can not execute Sonar
Embedded error: Unable to build project for plugin 'org.codehaus.sonar.runtime:sonar-core-maven-plugin': POM 'org.codehaus.sonar.runtime:sonar-core-maven-plugin' not found in repository: Unable to download the artifact from any repository
org.codehaus.sonar.runtime:sonar-core-maven-plugin:pom:20100531104729
from the specified remote repositories:
nexus (http://[[local_repositories]]/nexus/content/groups/public)
for project org.codehaus.sonar.runtime:sonar-core-maven-plugin
[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: < 1 second
[INFO] Finished at: Mon May 31 17:28:27 CEST 2010
[INFO] Final Memory: 3M/67M
[INFO] ------------------------------------------------------------------------ |
Ce que je ne comprends pas, c'est qu'il cherche à télécharger l'artefact Sonar des repositories locales, alors que j'ai configuré un miroir (comme vous pouvez le voir dans le post qui suit dans le fichier ~/.m2/settings.xml) spécialement pour Sonar afin qu'il le cherche dans http://repository.codehaus.org.
Peut-être mon settings.xml est-il mal renseigné ?
Merci d'avance !
Rolf IV