最近使用maven, 发现下载很慢, 发现可以修改settings.xml 来加载速度
<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<!-- This is a settings.xml file retrieved from http://nexus.magnolia-cms.com/ -->
<mirrors>
<mirror>
<id>maven.net.cn</id>
<name>one of the central mirrors in china</name>
<url>http://maven.oschina.net/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
在settings下填加mirrors节点, jar包会直接从这个站点下载了 http://maven.oschina.net/content/groups/public/
本文介绍了一种通过修改settings.xml文件中的mirrors节点来提高Maven下载速度的方法,具体操作为指定国内镜像站点。
1198

被折叠的 条评论
为什么被折叠?



