mvn install       --settings c:\user\settings.xml 
#mvn install       -s        c:\user\settings.xml 
mvn clean package --settings F:\Maven\settings.xml -Dmaven.test.skip=true
#mvn clean package -s        F:\Maven\settings.xml -Dmaven.test.skip=true

 

 

2. watch current maven setting info

mvn help:effective-settings

maven command line specified settings.xml

 

 

mvn help:system can print all java system properties  and os env variables.
mvn help:effective-pom用于查看当前生效的POM内容,指合并了所有父POM(包括Super POM)后的XML,所以可用于检测POM中某个配置是否生效
mvn effective-settings可用于查看当前生效的settings.xml文件内容,所以可用于判断某个settings配置是否生效

 

 

 

3. reference

http://stackoverflow.com/questions/1261215/maven-command-to-determine-which-settings-xml-file-maven-is-using
http://stackoverflow.com/questions/25277866/maven-command-line-how-to-point-to-a-specific-settings-xml-for-a-single-command

相关文章:

  • 2022-02-27
  • 2021-12-06
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-09
  • 2021-11-29
猜你喜欢
  • 2020-05-01
  • 2021-12-09
  • 2022-12-23
  • 2022-12-23
  • 2021-07-24
相关资源
相似解决方案