On Tue, 2003-01-14 at 10:58, Chan, Charles wrote:
> Yes, I agree that a child project should inherit its parent's goals.
> However, I also think it would be nice if a child project has a chance to
> override them if it has to.

This is how it works now.

If a parent maven.xml file is present it will be loaded before the
child's maven.xml file. This way all the goals specified in the parent's
maven.xml file will be available to the child but the child may override
any of the goals. Real object inheritance is the model we're shooting
for so any variation is more than likely an error on my part.

> Charles
> 
> 
> 
> -----Original Message-----
> From: James Ward [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, January 14, 2003 10:56 AM
> To: Turbine Maven Users List
> Subject: RE: Reactor test cases
> 
> 
> I think this might be more of a feature.  I believe that when I run
> maven in a subproject dir where my project.xml has an extend tag, Maven
> loads the root project's maven.xml file.  This is pretty nice because
> then I can put all my redundant goals in the maven.xml file and can use
> them whether or not I am in the reactor.
> 
> So, now in my root project, if I run the ec:dist goal it runs the
> ecs:dist goals for the subprojects.  And if I am in a subproject I just
> run the ecs:dist goal (All of which are specified in the root level
> maven.xml file)
> 
> So, personally I like this "feature".
> 
> -James
> 
> 
> On Tue, 2003-01-14 at 08:46, Chan, Charles wrote:
> > I don't know where the reactor test cases are... Anyway, I just encounter
> a
> > problem (or a feature) with reactor. If the master project's goal name is
> > the same as the child's goal, reactor won't invoke the goal.
> > 
> > So, in my master maven.xml, I have:
> > 
> > <project xmlns:m="jelly:maven">
> >   <goal name="test">
> >     <m:reactor basedir="${basedir}"
> >                includes="*/project.xml"
> >                goals="test"
> >                banner="Testing"
> >                ignoreFailures="false"/>
> >   </goal>
> > </project>
> > 
> > 
> > In my slave maven.xml, I have:
> > 
> > <project>
> >   <goal name="test">
> >     <echo>${pom.getCurrentVersion()}</echo>
> >   </goal>
> > </project>
> > 
> > If I run "maven test" in the master level, 
> > 
> >  __  __
> > |  \/  |__ Jakarta _ ___
> > | |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
> > |_|  |_\__,_|\_/\___|_||_|   v. 1.0-beta-8
> > 
> > 
> > [DEBUG] Adding reference: maven.dependency.classpath ->
> > [DEBUG] Adding reference: maven-classpath ->
> > Starting the reactor ...
> > test:
> > [DEBUG] Adding reference: maven.dependency.classpath ->
> > [DEBUG] Adding reference: maven-classpath ->
> > Our processing order:
> > Test Slave
> > +----------------------------------------
> > | Testing Test Slave
> > +----------------------------------------
> > Starting the reactor ...
> > Our processing order:
> > BUILD SUCCESSFUL
> > Total time:  2 seconds
> > 
> > Looks like the master's goal overrides the slave's goal....
> > 
> > Charles
> > 
> > --
> > To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> > 
> 
> 
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
-- 
jvz.

Jason van Zyl
[EMAIL PROTECTED]
http://tambora.zenplex.org

In short, man creates for himself a new religion of a rational
and technical order to justify his work and to be justified in it.
  
  -- Jacques Ellul, The Technological Society


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to