How to create a jar from part of my project that is packaged as a war

前端 未结 4 1487
旧时难觅i
旧时难觅i 2020-12-07 02:55

I\'m a Maven newbie, so I apologize if this is something trivial. Basically, I am developing a webapp, and I am using Maven to manage the project. I have

4条回答
  •  清歌不尽
    2020-12-07 03:27

    Use maven-jar-plugin, see :

    • http://maven.apache.org/plugins/maven-jar-plugin/usage.html

    Example:

        
            org.apache.maven.plugins
            maven-jar-plugin
                        
                            
                                 **/service/*
                            
                        
            
                
                    make-a-jar
                    compile
                    
                        jar
                    
                
            
        
    

提交回复
热议问题