This is an automated email from the ASF dual-hosted git repository. jbonofre pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/karaf.git
The following commit(s) were added to refs/heads/master by this push: new 218c765 [KARAF-5585] Do not provide maven settings to pax url if they are gone. 218c765 is described below commit 218c765d0ec389f44d27d9e837e965028aa30f15 Author: Ćukasz Dywicki <l...@code-house.org> AuthorDate: Wed Jan 31 14:01:42 2018 +0100 [KARAF-5585] Do not provide maven settings to pax url if they are gone. --- .../src/main/java/org/apache/karaf/tooling/VerifyMojo.java | 6 +++++- .../src/main/java/org/apache/karaf/tooling/utils/MojoSupport.java | 8 -------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/VerifyMojo.java b/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/VerifyMojo.java index fce9e55..3005a10 100644 --- a/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/VerifyMojo.java +++ b/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/VerifyMojo.java @@ -175,7 +175,11 @@ public class VerifyMojo extends MojoSupport { getLog().info("Using repositories: " + remoteRepositories); config.put("maven.repositories", remoteRepositories); config.put("maven.localRepository", localRepo.getBasedir()); - config.put("maven.settings", mavenSession.getRequest().getUserSettingsFile().toString()); + + if (mavenSession.getRequest().getUserSettingsFile().exists()) { + config.put("maven.settings", mavenSession.getRequest().getUserSettingsFile().toString()); + } + // TODO: add more configuration bits ? resolver = new ReactorMavenResolver(reactor, MavenResolvers.createMavenResolver(config, "maven")); doExecute(); diff --git a/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/utils/MojoSupport.java b/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/utils/MojoSupport.java index 3f0e06c..1837b74 100644 --- a/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/utils/MojoSupport.java +++ b/tooling/karaf-maven-plugin/src/main/java/org/apache/karaf/tooling/utils/MojoSupport.java @@ -128,14 +128,6 @@ public abstract class MojoSupport extends AbstractMojo { // called by Plexus when injecting the mojo's session public void setMavenSession(MavenSession mavenSession) { this.mavenSession = mavenSession; - - if (mavenSession != null) { - // check for custom settings.xml and pass it onto pax-url-aether - File settingsFile = mavenSession.getRequest().getUserSettingsFile(); - if (settingsFile != null && settingsFile.isFile()) { - System.setProperty("org.ops4j.pax.url.mvn.settings", settingsFile.getPath()); - } - } } protected Map createManagedVersionMap(String projectId, -- To stop receiving notification emails like this one, please contact jbono...@apache.org.