You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by GitBox <gi...@apache.org> on 2021/12/30 06:11:04 UTC

[GitHub] [maven-mvnd] Fzoss opened a new issue #553: Windows configuration mvn/conf/setting.xml does not take effect

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: issues-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] gnodet closed issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
gnodet closed issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553


   


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] gnodet commented on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
gnodet commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007490834


   I found out that the original problem raised in this issue is that the global settings file is not used at all.  The reason is that the `maven.conf` system property is not set at all by mvnd.


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] Fzoss commented on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
Fzoss commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007515872


   > I found out that the original problem raised in this issue is that the global settings file is not used at all. The reason is that the `maven.conf` system property is not set at all by mvnd.
   
   After I replaced the built-in maven "setting.xml" and found it invalid, I thought mvnd might just have to bring the "setting.xml" file, but mvnd wasn't going to use it.
   I didn't think it was a bug at the time, so I changed my mind and tried to change the location of "setting.xml" in maven.settings.


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] Fzoss edited a comment on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
Fzoss edited a comment on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007515872


   > I found out that the original problem raised in this issue is that the global settings file is not used at all. The reason is that the `maven.conf` system property is not set at all by mvnd.
   
   After I replaced the built-in maven `setting.xml` and found it invalid, I thought mvnd might just have to bring the `setting.xml` file, but mvnd wasn't going to use it.
   I didn't think it was a bug at the time, so I changed my mind and tried to change the location of `setting.xml` in maven.settings.


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] ppalaga commented on issue #553: Windows configuration mvn/conf/setting.xml does not take effect

Posted by GitBox <gi...@apache.org>.
ppalaga commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1004907021


   @Fzoss I guess the issue happens because backslash has a special meaning (escape character) in Java Property files. Could you please try whether the following works for you?
   ```
   maven.settings=C:\\ProgramData\\chocolatey\\lib\\maven\\apache-maven-3.8.3\\conf\\settings.xml
   ```


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] gnodet commented on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
gnodet commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007490834


   I found out that the original problem raised in this issue is that the global settings file is not used at all.  The reason is that the `maven.conf` system property is not set at all by mvnd.


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] Fzoss edited a comment on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
Fzoss edited a comment on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007515872


   > I found out that the original problem raised in this issue is that the global settings file is not used at all. The reason is that the `maven.conf` system property is not set at all by mvnd.
   
   After I replaced the built-in maven `setting.xml` and found it invalid, I thought mvnd might just have to bring the `setting.xml` file, but mvnd wasn't going to use it.
   I didn't think it was a bug at the time, so I changed my mind and tried to change the location of `setting.xml` in maven.settings.


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] mstao commented on issue #553: Windows configuration mvn/conf/setting.xml does not take effect

Posted by GitBox <gi...@apache.org>.
mstao commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1003255809


   Hi, you can use `./mvn/conf/settings.xml` , such as :
   
   ```
   maven.settings=E://D//software//mvnd-0.7.1-windows-amd64//mvn//conf//settings.xml
   ```


-- 
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-unsubscribe@maven.apache.org

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



[GitHub] [maven-mvnd] Fzoss commented on issue #553: The ${MVND_HOME}/mvn/conf/setting.xml is not used

Posted by GitBox <gi...@apache.org>.
Fzoss commented on issue #553:
URL: https://github.com/apache/maven-mvnd/issues/553#issuecomment-1007515872


   > I found out that the original problem raised in this issue is that the global settings file is not used at all. The reason is that the `maven.conf` system property is not set at all by mvnd.
   
   After I replaced the built-in maven "setting.xml" and found it invalid, I thought mvnd might just have to bring the "setting.xml" file, but mvnd wasn't going to use it.
   I didn't think it was a bug at the time, so I changed my mind and tried to change the location of "setting.xml" in maven.settings.


-- 
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-unsubscribe@maven.apache.org

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