成都网站建设设计

将想法与焦点和您一起共享

Maven中解决system的jar依赖,打包复制问题

依赖管理配置:

创新互联建站专注于企业网络营销推广、网站重做改版、綦江网站定制设计、自适应品牌网站建设、HTML5商城网站定制开发、集团公司官网建设、外贸网站建设、高端网站制作、响应式网页设计等建站业务,价格优惠性价比高,为綦江等各大城市提供网站开发制作服务。


    com.alibaba
    fastjson
    1.2.29
    system
    
    E:/projectsx/lecing/lecing5/code/back/lib/fastjson-1.2.29-SNAPSHOT.jar

依赖配置:


    com.alibaba
    fastjson

build配置:

父POM中:


    ${project.artifactId}
    
        
            ${basedir}/src/main/java
            
                **/*.xml
                **/*.properties
            
        
        
            ${basedir}/src/main/resources
        
    
    
        
            
            
                org.apache.maven.plugins
                maven-resources-plugin
                2.7
                
                    UTF-8
                
            
            
            
                org.apache.maven.plugins
                maven-compiler-plugin
                3.5.1
                
                    1.8
                    1.8
                    UTF-8
                
            
        
    

子POM中:


    
        
            ${basedir}/src/main/java
            
                **/*.xml
                **/*.properties
            
        
        
            ${basedir}/src/main/resources
        
    
    
        
            org.apache.maven.plugins
            maven-dependency-plugin
            3.0.2
            
                
                    package
                    
                        copy-dependencies
                    
                
            
            
                system
                ${project.build.directory}/${project.build.finalName}/WEB-INF/lib
            
        
    

子POM中的插件才是解决的关键。


网站标题:Maven中解决system的jar依赖,打包复制问题
浏览路径:http://chengdu.cdxwcx.cn/article/gipgho.html