Eclipse配置Maven阿里云镜像仓库
程序员文章站
2022-07-13 13:47:57
...
找到Maven依赖的目录。相关命令:cd ~/.m2
在该目录下添加配置文件:setting.xml。相关命令: vim ~/.m2/setting.xml
配置如下:
<settings>
<mirrors>
<mirror>
<id>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
</mirrors>
</settings>
或
<settings>
<mirrors>
<mirror>
<id>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/repositories/central</url>
</mirror>
</mirrors>
</settings>
Eclipse指定Maven配置文件
亲测可用!