Profile activation on both release:prepare and release:perform

前端 未结 4 1558
长发绾君心
长发绾君心 2020-12-30 05:17

I cannot find a solution for activating some Maven profile on release:prepare and release:perform (both) goals. Something like this:



        
4条回答
  •  青春惊慌失措
    2020-12-30 05:35

    Because maven release plugin start additional instance you have to specify additional arguments. For you case

    
        org.apache.maven.plugins
        maven-release-plugin
        2.4
        
            ${myReleaseArgs}
        
    
    

    and execution

    mvn release:prepare release:perform -DmyReleaseArgs="-Pmy-release -DskipTests=true" -Pmy-release -DskipTests=true
    

    and yes it must be duplicated.

提交回复
热议问题