There is an attribute that you can specify to indicate that you are
appending elements rather than replacing... if only I could remember it!

2008/9/29 tjunak <[EMAIL PROTECTED]>

>
> I've checked it again - every time a whole list is overriden not elements
> on
> the list.
> I have made few tries on different plugins - and the result is always the
> same.
>
> I have dozens of child-pom where their configuration in many cases differ a
> little.
> It looks that it is needed to move whole configuration from Parent-Pom into
> every child pom that need even a slight change in configuration (one extra
> element on the list).  I hoped to keep common settings in Parent-Pom and
> that I could add specific options in some child-poms. But then in that case
> it is very hard to maintain - especially in a corporate level projects.
>
> Isn't it a bug?
>
> How does the merging work in Maven in case of list structure ?
>
> Thank you for any help!
>
>
> Baptiste MATHUS-4 wrote:
> >
> > Hi,
> >
> > You should try <pluginManagement> node to manage this, see
> > http://maven.apache.org/pom.html#Plugin_Management.
> >
> > Cheers.
> >
> > 2008/9/25 tjunak <[EMAIL PROTECTED]>
> >
> >>
> >> Hi,
> >>
> >> I have a following problem with plugin inheritance.
> >>
> >> I have put a plugin with lot of configuration in Parent-Pom, there are
> >> lot
> >> of child-poms in the project.
> >> Most of them use the plugin configuration but in some cases I have to
> >> re-define some options.
> >> Let's say:
> >>
> >> Parent-Pom:
> >>
> >> <plugin>
> >> <artifactId>my-plugin</artifactId>
> >>
> >>  <configuration>
> >>
> >>  <defines>
> >>   <define>def-A</define>
> >>   <define>def-B</define>
> >>  </defines>
> >>
> >>  </configuration>
> >>
> >> </plugin>
> >>
> >> In my real project there are much more such lists and elements.
> >>
> >>
> >>
> >> Child-Pom:
> >>
> >> Here I have to add some special define:
> >>
> >> <plugin>
> >> <artifactId>my-plugin</artifactId>
> >>
> >>  <configuration>
> >>
> >>  <defines>
> >>   <define>def-C</define>
> >>  </defines>
> >>
> >>  </configuration>
> >>
> >> </plugin>
> >>
> >>
> >> The problem is that when I'm checking this with help:effective-pom I get
> >> only this:
> >>
> >> <defines>
> >>  <define>def-C</define>
> >> </defines>
> >>
> >> which means whole list is overriden not elements on the list.
> >>
> >> My expectation is to get:
> >>
> >> <defines>
> >>  <define>def-A</define>
> >>  <define>def-B</define>
> >>  <define>def-C</define>
> >> </defines>
> >>
> >> This causes that in a lot of child-poms I have re-write almost all
> >> configuration from Parent-Pom which
> >> of course will be later hard to maintain.
> >>
> >> Is there a way to inherit it on list elements level with Maven ?
> >>
> >> Thank you in advance!
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Plugin-inheritance-tp19664782p19664782.html
> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> >
> > --
> > Baptiste <Batmat> MATHUS - http://batmat.net
> > Sauvez un arbre,
> > Mangez un castor !
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Plugin-inheritance-tp19664782p19722688.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to