Maven修改默认仓库为阿里云仓库
生活随笔
收集整理的這篇文章主要介紹了
Maven修改默认仓库为阿里云仓库
小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
Maven 倉(cāng)庫(kù)默認(rèn)在國(guó)外, 國(guó)內(nèi)使用難免很慢,我們可以更換為阿里云的倉(cāng)庫(kù)。
第一步:修改 maven 根目錄下的 conf 文件夾中的 setting.xml 文件,在 mirrors 節(jié)點(diǎn)上,添加內(nèi)容如下:
<mirrors><mirror><id>alimaven</id><name>aliyun maven</name><url>http://maven.aliyun.com/nexus/content/groups/public/</url><mirrorOf>central</mirrorOf> </mirror> </mirrors>
第二步: pom.xml文件里添加:
<repositories> <repository> <id>alimaven</id> <name>aliyun maven</name> <url>http://maven.aliyun.com/nexus/content/groups/public/</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>false</enabled> </snapshots> </repository> </repositories>
轉(zhuǎn)載于:https://www.cnblogs.com/ttty/p/10307770.html
總結(jié)
以上是生活随笔為你收集整理的Maven修改默认仓库为阿里云仓库的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: hadoop启动
- 下一篇: 安装oracle 11g时,报启动服务出