yuicompressor maven plugin and maven-war-plugin

前端 未结 7 1393
走了就别回头了
走了就别回头了 2020-12-24 03:34

I\'ve been struggling with getting this plugin to play nicely with the maven-war-plugin for a couple of hours now and I thought it was time to ask for help. I have the plugi

7条回答
  •  北海茫月
    2020-12-24 04:05

    OK. I finally figured this out. You need to define a in the yuicompressor plugin that can then be referenced as a in the maven-war-plugin. In the example below I'm using ${project.build.directory}/min

    
        net.alchim31.maven
        yuicompressor-maven-plugin
        1.3.0
        
            
                compressyui
                process-resources
                
                    compress
                
                
                    true
                    ${basedir}/WebContent
                    ${project.build.directory}/min
                    false
                
            
        
    
    
        maven-war-plugin
        
            
                default-war
                package
                
                    war
                
                
                    ${basedir}/WebContent
                    UTF-8
                
            
        
        
            ${basedir}/WebContent
            UTF-8
            
                
                    ${project.build.directory}/min
                
            
        
    
    

提交回复
热议问题