diff options
author | Godin <mandrikov@gmail.com> | 2010-09-27 15:27:44 +0000 |
---|---|---|
committer | Godin <mandrikov@gmail.com> | 2010-09-27 15:27:44 +0000 |
commit | 4fdde0e6906ec693fbbd02bf2fcc818e4277ad0a (patch) | |
tree | 060808b4cb27991355cb969edc811607b88c0926 /subprojects | |
parent | 4193099ff2d1baa0e687b98763e3556b91f6fea6 (diff) | |
download | sonarqube-4fdde0e6906ec693fbbd02bf2fcc818e4277ad0a.tar.gz sonarqube-4fdde0e6906ec693fbbd02bf2fcc818e4277ad0a.zip |
SONAR-1815: Fix packaging of dependencies when groupId=org.codehaus.sonar
Diffstat (limited to 'subprojects')
-rw-r--r-- | subprojects/sonar-update-center/sonar-packaging-maven-plugin/src/main/java/org/sonar/updatecenter/mavenplugin/SonarPluginMojo.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/subprojects/sonar-update-center/sonar-packaging-maven-plugin/src/main/java/org/sonar/updatecenter/mavenplugin/SonarPluginMojo.java b/subprojects/sonar-update-center/sonar-packaging-maven-plugin/src/main/java/org/sonar/updatecenter/mavenplugin/SonarPluginMojo.java index 2caa56b4582..a8be99640fe 100644 --- a/subprojects/sonar-update-center/sonar-packaging-maven-plugin/src/main/java/org/sonar/updatecenter/mavenplugin/SonarPluginMojo.java +++ b/subprojects/sonar-update-center/sonar-packaging-maven-plugin/src/main/java/org/sonar/updatecenter/mavenplugin/SonarPluginMojo.java @@ -306,7 +306,10 @@ public class SonarPluginMojo extends AbstractSonarPluginMojo { private void searchForSonarProvidedArtifacts(DependencyNode dependency, Set<Artifact> sonarArtifacts, boolean isProvidedBySonar) { if (dependency != null) { - isProvidedBySonar = isProvidedBySonar || ("org.codehaus.sonar".equals(dependency.getArtifact().getGroupId()) && !Artifact.SCOPE_TEST.equals(dependency.getArtifact().getScope())); + // skip check on root node - see SONAR-1815 + if (dependency.getParent() != null) { + isProvidedBySonar = isProvidedBySonar || ("org.codehaus.sonar".equals(dependency.getArtifact().getGroupId()) && !Artifact.SCOPE_TEST.equals(dependency.getArtifact().getScope())); + } if (isProvidedBySonar) { sonarArtifacts.add(dependency.getArtifact()); |