Fzoss opened a new issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553


   When I installed it on the windows system and replaced the conf/setting.xml 
in mvn in the directory with the configuration I used normally, it didn’t seem 
to take effect, which made me unable to package normally.
   
   After researching, it seems that the configuration can be specified through 
maven.settings in mvnd.properties. The example given is {@code 
~/.m2/settings.xml}.
   In other words, I can directly specify my configuration file here, so I 
wrote this:
   
maven.settings=C:\ProgramData\chocolatey\lib\maven\apache-maven-3.8.3\conf\settings.xml
   
   But it still didn't work when I tested it.
   For example, when I compile under D:/root, mvnd tells me that the directory 
of setting.xml is: 
D:/root\C:ProgramDatachocolateylibmavenapache-maven-3.8.3confsettings.xml
   
   After flipping through, I found this:
   https://github.com/apache/maven-mvnd/issues/383
   Thanks to @ppalaga for providing an example: /path/to/settings.xml
   It made me realize that it may be because the directory symbol "\" under 
windows is considered to be an escape character
   I tried to modify it
   
maven.settings=C:/ProgramData/chocolatey/lib/maven/apache-maven-3.8.3/conf/settings.xml
   everything is normal
   
   I recommend using File.separator to determine the file symbol of the current 
system and replace the configurationWhen I installed it on the windows system 
and replaced the conf/setting.xml in mvn in the directory with the 
configuration I used normally, it didn’t seem to take effect, which made me 
unable to package normally.
   
   After researching, it seems that the configuration can be specified through 
maven.settings in mvnd.properties. The example given is {@code 
~/.m2/settings.xml}.
   In other words, I can directly specify my configuration file here, so I 
wrote this:
   
maven.settings=C:\ProgramData\chocolatey\lib\maven\apache-maven-3.8.3\conf\settings.xml
   
   But it still didn't work when I tested it.
   For example, when I compile under D:/root, mvnd tells me that the directory 
of setting.xml is: 
D:/root\C:ProgramDatachocolateylibmavenapache-maven-3.8.3confsettings.xml
   
   After flipping through, I found this:
   https://github.com/apache/maven-mvnd/issues/383
   Thanks to @ppalaga for providing an example: /path/to/settings.xml
   It made me realize that it may be because the directory symbol "\" under 
windows is considered to be an escape character
   I tried to modify it
   
maven.settings=C:/ProgramData/chocolatey/lib/maven/apache-maven-3.8.3/conf/settings.xml
   everything is normal
   
   I recommend using File.separator to determine the file symbol of the current 
system and replace the configuration


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to