首页 > 其他 > 详细

maven下载速度慢的解决方法(转)

时间:2017-01-03 20:37:39      阅读:185      评论:0      收藏:0      [点我收藏+]

原文链接:http://blog.csdn.net/u013009618/article/details/53980983

maven是支持镜像的,我们可以在maven的conf文件加下的setting.xml文件中找到<mirrors></mirrors>标签

 

<mirrors>  
    <!-- mirror  
     | Specifies a repository mirror site to use instead of a given repository. The repository that  
     | this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used  
     | for inheritance and direct lookup purposes, and must be unique across the set of mirrors.  
     |  
    <mirror>  
      <id>mirrorId</id>  
      <mirrorOf>repositoryId</mirrorOf>  
      <name>Human Readable Name for this Mirror.</name>  
      <url>http://my.repository.com/repo/path</url>  
    </mirror>  
     -->  
      
  </mirrors>  

 

 

 

在这个标签中加入国内的镜像即可,在这里推荐阿里云的镜像,下载速度有明显的加快

 

<mirror>  
 <id>alimaven</id>  
 <mirrorOf>central</mirrorOf>  
 <name>aliyun maven</name>  
 <url>http://maven.aliyun.com/nexus/content/repositories/central/</url>  
</mirror>  

 

maven下载速度慢的解决方法(转)

原文:http://www.cnblogs.com/aigeileshei/p/6245964.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!