maven配置中国下载源【转:http://www.cnblogs.com/libingbin/p/5949483.html】

修改 配置文件

maven 安装 路径

F:\apache-maven-3.3.9\conf

修改 settings.xml或者在.m2文件夹下新建一个settings.xml

阿里源

<mirror>
        <id>nexus-aliyunid>
        <mirrorOf>centralmirrorOf>
        <name>Nexus aliyunname>
        <url>http://maven.aliyun.com/nexus/content/groups/publicurl>
mirror>

 




添加 如下 内容 访问 开源中国的jar 下载源

 



CN
OSChina Central 
http://maven.oschina.net/content/groups/public/
central

 ---------------------------------------------------------------------------------------------------------------------------

以下是完整的:settings.xml






          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">
  

  

  

  
  
    
  

  
  
    
  

  
  
    

    
  

  
  
    
          repo2
          central
          Human Readable Name for this Mirror.
          http://repo2.maven.org/maven2/
    
    
          net-cn
          central
          Human Readable Name for this Mirror.
          http://maven.net.cn/content/groups/public/
    
    
          ui
          central
          Human Readable Name for this Mirror.
         http://uk.maven.org/maven2/
    
    
          ibiblio
          central
          Human Readable Name for this Mirror.
         http://mirrors.ibiblio.org/pub/mirrors/maven2/
    
    
          jboss-public-repository-group
          central
          JBoss Public Repository Group
         http://repository.jboss.org/nexus/content/groups/public
    
     
      CN
      OSChina Central
      http://maven.oschina.net/content/groups/public/
      central
    

  

  
  
    

    
  

  

 

转载于:https://www.cnblogs.com/zipon/p/6042776.html

你可能感兴趣的:(maven配置中国下载源【转:http://www.cnblogs.com/libingbin/p/5949483.html】)