maven配置文件 setting.xml设置和设置阿里云镜像

settings.xml通用配置

官网链接

一般格式:

<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
                          https://maven.apache.org/xsd/settings-1.0.0.xsd">
      <localRepository/>
      <interactiveMode/>
      <usePluginRegistry/>
      <offline/>
      <pluginGroups/>
      <servers/>
      <mirrors/>
      <proxies/>
      <profiles/>
      <activeProfiles/>
    settings>

阿里云镜像配置


    
      alimaven
      aliyun maven
      
          http://maven.aliyun.com/nexus/content/groups/public/
      
      central        
    
  

其他镜像

<mirrors>
        
        <mirror>
            <id>maven.net.cnid>
            <name>oneof the central mirrors in chinaname>
            <url>http://maven.net.cn/content/groups/public/url>
            <mirrorOf>centralmirrorOf>
        mirror>
        <mirror>
            <id>alimavenid>
            <name>aliyun mavenname>
            <url>http://maven.aliyun.com/nexus/content/groups/public/url>
            <mirrorOf>centralmirrorOf>
        mirror>
        <mirror>
            <id>centralid>
            <name>Maven Repository Switchboardname>
            <url>http://repo1.maven.org/maven2/url>
            <mirrorOf>centralmirrorOf>
        mirror>
        <mirror>
            <id>repo2id>
            <mirrorOf>centralmirrorOf>
            <name>Human Readable Name for this Mirror.name>
            <url>http://repo2.maven.org/maven2/url>
        mirror>
        <mirror>
            <id>ibiblioid>
            <mirrorOf>centralmirrorOf>
            <name>Human Readable Name for this Mirror.name>
            <url>http://mirrors.ibiblio.org/pub/mirrors/maven2/url>
        mirror>
        <mirror>
            <id>jboss-public-repository-groupid>
            <mirrorOf>centralmirrorOf>
            <name>JBoss Public Repository Groupname>
            <url>http://repository.jboss.org/nexus/content/groups/publicurl>
        mirror>

你可能感兴趣的:(web工具)