maven项目如何从私服nexus中下载依赖包

2023-06-25,,

maven项目如何从私服nexus中下载依赖

 

解决方法:

1.打开maven的config目录中settings.xml文件

2.在<profile></profiles>之间添加以下代码:

<profile>

<id>central</id>

<repositories>

<repository>

<id>central</id>

<url>http://gisserver2:9081/nexus/content/groups/public/</url>

<releases>

<enabled>true</enabled>

</releases>

<snapshots>

<enabled>true</enabled>

</snapshots>

</repository>

</repositories>

</profile>

3.在<profile></profiles>后面添加以下代码(使配置文件始终处于活动状态):

<activeProfiles>

<activeProfile>central</activeProfile>

</activeProfiles>

maven项目如何从私服nexus中下载依赖包的相关教程结束。

《maven项目如何从私服nexus中下载依赖包.doc》

下载本文的Word格式文档,以方便收藏与打印。