Hot to disable buildnumber-maven-plugin through cmd

前端 未结 4 730
故里飘歌
故里飘歌 2021-01-18 20:02

I have question about maven. How can I disable buildnumber-maven-plugin through command line option. I want to run \"mvn test\" command on our continuous integration server,

4条回答
  •  庸人自扰
    2021-01-18 20:40

    Use a profile to control which plug-ins are enabled during the build:

    
        4.0.0
        com.me.test
        demo
        1.0
        ..
        ..
        
            
                with-scm
                
                    
                        
                            org.codehaus.mojo
                            buildnumber-maven-plugin
                            1.0
                            
                                
                                    validate
                                    
                                        create
                                    
                                
                            
                            
                                true
                                true
                            
                        
                    
                
            
        
    
    

    The profile can be enabled by running Maven as follows:

    mvn -Pwith-scm package
    

提交回复
热议问题