您的位置:首页 > 其它

maven搜索仓库

2016-01-18 22:03 393 查看
——爱迪生经过1001次实验成功发明了电灯

1、maven搜索服务

   国外常见maven仓库:可能打开很慢甚至无法打开,解决方案。代理、svn或国内maven搜索仓库

  1.1 Sonatype Nexus

  http://repository.sonatype.org/
  1.2 Jarvana

  http://www.jarvana.com/

  1.3MVNbrowser

  http://www.mvnbrowser.com

  1.4 MVNrepository (访问速度比上面三个快些)

  http://mvnrepository.com/

2、配置maven下载地址

http://repo1.maven.org/maven2/ 是真正的Maven中央仓库的地址,该地址内置在Maven的源码中。也是默认jar包下载地址,我们可以通过setting.xml配置文件,配置指定下载地址。

修改setting.xml文件。默认在maven目录下的conf目录下。

例如:打开settring.xml文件,在<mirrors>标签对内插入<mirror>标签对

<mirrors>
<mirror>
<id>CN</id>
<name>OSChina Central</name>
<url>http://maven.oschina.net/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>


• 由于在国内连接外国maven可能会很慢,整理一些国内maven仓库。

====================国内OSChina提供的镜像,非常不错===================

<mirror>

<id>CN</id>
<name>OSChina Central</name>
<url>http://maven.oschina.net/content/groups/public/</url>
<mirrorOf>central</mirrorOf>

</mirror>

========================================================

OSChina Maven 库使用帮助

==================其他maven仓库镜像==========================

<mirror>
<id>repo2</id>
<mirrorOf>central</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://repo2.maven.org/maven2/</url>
</mirror>
<mirror>
<id>net-cn</id>
<mirrorOf>central</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://maven.net.cn/content/groups/public/</url>
</mirror>
<mirror>
<id>ui</id>
<mirrorOf>central</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://uk.maven.org/maven2/</url>
</mirror>
<mirror>
<id>ibiblio</id>
<mirrorOf>central</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://mirrors.ibiblio.org/pub/mirrors/maven2/</url>
</mirror>
<mirror>
<id>jboss-public-repository-group</id>
<mirrorOf>central</mirrorOf>
<name>JBoss Public Repository Group</name>
<url>http://repository.jboss.org/nexus/content/groups/public</url>
</mirror>

原文地址

时间:2016年1月18日21:46:45

备注:内容整理于网络
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: