Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有什么方法可以在 Maven 构建中执行特定阶段。例如,如果我只想运行那些在预集成阶段执行的插件,Maven 是否提供了一种方法来做到这一点?
e.g. mvn pre-integration-phase
您不能调用生命周期阶段本身,但您可以调用绑定到生命周期阶段的插件的目标。
mvn compile:testCompile mvn failsafe:integration-test
但通常这不应该是必需的......
不,您必须手动运行插件。