开发者

How to make a maven plugin not run on all of my project modules

开发者 https://www.devze.com 2023-04-10 16:08 出处:网络
I have a multi module web app that is using maven 3, an EJB, WAR, and EAR modules used to build the app. I want to add dbDeploy to my app and have tried adding the plugin and correct directories and d

I have a multi module web app that is using maven 3, an EJB, WAR, and EAR modules used to build the app. I want to add dbDeploy to my app and have tried adding the plugin and correct directories and dependencies to the top level pom file(in the directory with the ear,ejb,war project directories). But when I try to run dbdeploy:update in the top directory it correctly runs it in my current directory but then it tries running it again in each of the modules of my project where it fails.

My question is, is there an开发者_高级运维yway to tell maven not to run a plugin on each of my modules and only inside the top level pom? I have also looked but it does not seem like dbdeploy supports a skip parameter as part of its configuration.

Thanks!


Place your dbdeploy plugin within pluginManagement section of parent pom. Then use the plugin in whichever project/pom that you need to (including the parent).

Refer to pluginManagement section in maven pom reference.

0

精彩评论

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