Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Automatically activate parent plugin in Maven

Is it possible to have a plugin defined in the parent POM which is deactivated, and when the child inherits this plugin it gets automatically activated?

like image 508
kukudas Avatar asked Jan 30 '09 12:01

kukudas


1 Answers

I guess you want to configure the plugin in your parent pom, but use it only in the inherited projects. Maven has a section for this - configure your plugins in pluginManagement, but bind them to a phase just when you needed it, e.g. omit the phase tag in pluginManagement, but specify it under in you inherited pom.

like image 95
siddhadev Avatar answered Oct 07 '22 05:10

siddhadev