From f151b661dd1d78677a93aceeb95328ec43a6f106 Mon Sep 17 00:00:00 2001 From: Jason van Zyl Date: Sat, 10 Feb 2007 02:01:00 +0000 Subject: [PATCH] o fixing finding of settings file Submitted by: Eugene Kuleshove git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@505611 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/maven/settings/DefaultMavenSettingsBuilder.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/maven-settings/src/main/java/org/apache/maven/settings/DefaultMavenSettingsBuilder.java b/maven-settings/src/main/java/org/apache/maven/settings/DefaultMavenSettingsBuilder.java index 14b320bc1d..ebd29d0d17 100644 --- a/maven-settings/src/main/java/org/apache/maven/settings/DefaultMavenSettingsBuilder.java +++ b/maven-settings/src/main/java/org/apache/maven/settings/DefaultMavenSettingsBuilder.java @@ -51,6 +51,11 @@ public class DefaultMavenSettingsBuilder { Settings globalSettings = readSettings( globalSettingsFile ); + if ( userSettingsFile == null ) + { + userSettingsFile = new File( new File( System.getProperty( "user.home" ) ), ".m2/settings.xml" ); + } + Settings userSettings = readSettings( userSettingsFile ); if ( globalSettings == null )