azaretsky commented on a change in pull request #566:
URL: https://github.com/apache/maven/pull/566#discussion_r722340594



##########
File path: 
maven-embedder/src/main/java/org/apache/maven/cli/configuration/SettingsXmlConfigurationProcessor.java
##########
@@ -90,15 +90,15 @@ public void process( CliRequest cliRequest )
         throws Exception
     {
         CommandLine commandLine = cliRequest.getCommandLine();
-        String workingDirectory = cliRequest.getWorkingDirectory();
+        String multiModuleDirectory = 
cliRequest.getMultiModuleProjectDirectory().toString();
         MavenExecutionRequest request = cliRequest.getRequest();
 
         File userSettingsFile;
 
         if ( commandLine.hasOption( CLIManager.ALTERNATE_USER_SETTINGS ) )
         {
             userSettingsFile = new File( commandLine.getOptionValue( 
CLIManager.ALTERNATE_USER_SETTINGS ) );
-            userSettingsFile = resolveFile( userSettingsFile, workingDirectory 
);
+            userSettingsFile = resolveFile( userSettingsFile, 
multiModuleDirectory );

Review comment:
       Is it the expected behaviour to always resolve the path to settings file 
against the multi module root, even if it is specified directly through the 
command line, and not in .mvn/maven.config?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to