Overriding Maven plugin goal definition for a given execution id

前端 未结 2 1750
無奈伤痛
無奈伤痛 2021-02-06 13:54

It doesn\'t seem to possible to override a plugin execution\'s goal definition.

Let say I have a parent config of Jetty, that defines a

                         


        
相关标签:
2条回答
  • 2021-02-06 14:31

    The way I found is to disable inherited configuration and creating a new one:

                        <execution>
                            <id>start-jetty</id>
                            <phase>none</phase>
                        </execution>
                        <execution>
                            <id>my-start-jetty</id>
                            <phase>pre-integration-test</phase>
                            <goals>
                                <goal>run-exploded</goal>
                            </goals>
                        </execution>
    
    0 讨论(0)
  • 2021-02-06 14:32

    Well this is inheritance working the way as designed. You should consider removing your jetty config from the parent pom and put it in a profile or your try the <inherited> element with value false and see if this works for you.

    0 讨论(0)
提交回复
热议问题