开发者

How does plugin specific configuration gets interpreted during runtime

开发者 https://www.devze.com 2023-03-28 10:31 出处:网络
I have a parent POM which defines maven-compiler-plugin definition/configuration under pluginManagement.plugins.plugin.

I have a parent POM which defines maven-compiler-plugin definition/configuration under pluginManagement.plugins.plugin.

I have a multi-module project which has a requirement to re-define the configuration for their respective modules (e.g. moduleA, moduleB). Since the definitions are inherited can I be assured that configuration specific to moduleA, moduleB will be used while performing the build.

e.g. moduleA wants to use jdk 1.5 to compile and moduleB wants to use JDK 1.6 to compile.

How should this be defined in the POM files? Do I need to define anything in the parent POM or should I just define compiler-plugin with respective configuration开发者_开发百科s on moduleA, moduleB.


You can simply just define the compiler plugin with its appropriate configuration part which you need. But don't define the version of the compiler plugin this is inherited via the pluginManagement part.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号