maven配置

1.配置IDE构建的Maven存放目录(解压目录)

2.配置IDE的User setting file路径,修改setting配置文件

配置本地仓库

   自定义本地仓库路径

   D:\Program Files\Develop\Portable\localRepository

配置mirrors远程镜像(一般配置一到两个镜像)


    
        alimaven
        aliyun maven
        https://maven.aliyun.com/repository/public
        central
    
    
        alimaven-central
        aliyun maven central
        https://maven.aliyun.com/repository/central
        central
    
    
        alimaven-spring
        aliyun maven-spring
        https://maven.aliyun.com/repository/spring
        central
    
    
        central
        Maven Repository Switchboard
        https://repo1.maven.org/maven2/
        central
    
    
        jboss-public-repository-group
        central
        JBoss Public Repository Group
        http://repository.jboss.org/nexus/content/groups/public
    
    
        spring-snapshots
        central
        Spring Snapshots
        https://repo.spring.io/snapshot
    
    
        spring-milestones
        central
        Spring Milestones
        https://repo.spring.io/milestone
    

配置profiles构建


    jdk18
    
        1.8
        true
    
    
        1.8
        1.8
        1.8
    

国内Maven镜像仓库值得收藏


     
        alimaven
        aliyun maven
        http://maven.aliyun.com/mvn/view
        central
    
    
        jboss-public-repository-group
        central
        JBoss Public Repository Group
        http://repository.jboss.org/nexus/content/groups/public
    
    
        ibiblio
        central
        Human Readable Name for this Mirror.
        https://maven.aliyun.com/mvn/view
    
    
        central
        Maven Repository Switchboard
        http://repo1.maven.org/maven2/
        central
    
    
        repo2
        central
        Human Readable Name for this Mirror.
        http://repo2.maven.org/maven2/
    

完整setting配置



    
    D:\Program Files\Develop\Portable\localRepository
    
    

    
    

    
    

    
        
        
            alimaven
            aliyun maven
            https://maven.aliyun.com/repository/public
            central
        
        
            alimaven-central
            aliyun maven central
            https://maven.aliyun.com/repository/central
            central
        
        
            alimaven-spring
            aliyun maven-spring
            https://maven.aliyun.com/repository/spring
            central
        
        
            central
            Maven Repository Switchboard
            https://repo1.maven.org/maven2/
            central
        
        
            jboss-public-repository-group
            central
            JBoss Public Repository Group
            http://repository.jboss.org/nexus/content/groups/public
        
        
            spring-snapshots
            central
            Spring Snapshots
            https://repo.spring.io/snapshot
        
        
            spring-milestones
            central
            Spring Milestones
            https://repo.spring.io/milestone
        
    

    
        
            jdk18
            
                1.8
                true
            
            
                1.8
                1.8
                1.8
            
        
    

来源于http://www.cnblogs.com/zengming/

你可能感兴趣的:(maven配置)