解决方法:

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>

相关文章:

  • 2021-12-05
  • 2021-07-02
  • 2021-07-26
  • 2021-10-01
  • 2021-06-01
  • 2022-12-23
  • 2022-12-23
  • 2021-12-07
猜你喜欢
  • 2021-07-10
  • 2021-07-02
  • 2021-09-16
  • 2021-08-24
  • 2021-07-12
  • 2021-04-20
  • 2022-12-23
相关资源
相似解决方案