最近使用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/