maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arnaud HERITIER" <aherit...@gmail.com>
Subject Re: Custom lifecycle and parameters in mojos
Date Thu, 23 Aug 2007 20:06:09 GMT
Hey Jason,

  I had a look at it, and I tried to create a lifecycle.xml descriptor
but it doesn't do what I want.
  In my component.xml I have :
    <component>
      <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role>
      <role-hint>grails-app</role-hint>
      <implementation>org.apache.maven.lifecycle.mapping.DefaultLifecycleMapping</implementation>
      <configuration>
        <lifecycles>
          <lifecycle>
            <id>default</id>
            <!-- START SNIPPET: default grails-lifecycle -->
           <phases>
<initialize>org.apache.maven.plugins:maven-dependency-plugin:copy-dependencies</initialize>
              <package>com.octo.mtg:grails-maven-plugin:maven-war</package>
              <install>org.apache.maven.plugins:maven-install-plugin:install</install>
              <deploy>org.apache.maven.plugins:maven-deploy-plugin:deploy</deploy>
            </phases>
            <!-- END SNIPPET: default grails-lifecycle -->
          </lifecycle>
        </lifecycles>
      </configuration>
    </component>

  and in the lifecycle.xml I have :

<lifecycles>
  <lifecycle>
    <id>default</id>
    <phases>
      <phase>
        <id>initialize</id>
        <configuration>
          <outputDirectory>${basedir}/lib</outputDirectory>
          <excludedScope>provided</excludedScope>
        </configuration>
      </phase>
    </phases>
  </lifecycle>
</lifecycles>

But when I launch maven I have :
[INFO] [dependency:copy-dependencies]
[INFO] Copying antlr-2.7.6.jar to
E:\OCTO\my-grails-app\target\dependency\antlr-2.7.6.jar
[INFO] Copying aspectjrt-1.5.3.jar to
E:\OCTO\my-grails-app\target\dependency\aspectjrt-1.5.3.jar
...

My dependencies are copied in the target/dependency directory and not
in ${basedir}/lib.
And the excludeScope doesn't seem to be used also.

Any Idea ? I think I forgot something trivial but I don't see.

Arnaud


On 23/08/07, Jason van Zyl <jason@maven.org> wrote:
>
> On 23 Aug 07, at 8:46 AM 23 Aug 07, Arnaud HERITIER wrote:
>
> > Is it possible with a META-INF/maven/lifecycle.xml instead of
> > META-INF/plexus/component.xml.
> >
> > I don't find a documentation about all of this. I need your help.
> >
>
> Look at the clover plugin for an example.
>
> > Thx
> >
> > Arnaud
> >
> > On 23/08/07, Arnaud HERITIER <aheritier@gmail.com> wrote:
> >> Hi Guys,
> >>
> >>   In a custom lifecycle I would like to use the dependency plugin
> >> (the
> >> copy-dependencies mojo to be exact) but I want to set some of its
> >> parameters (outputDirectory, excludedScopes).
> >>
> >>   Can I?
> >>   How ?
> >>
> >> --
> >> ..........................................................
> >> Arnaud HERITIER
> >> ..........................................................
> >> OCTO Technology - aheritier AT octo DOT com
> >> www.octo.com | blog.octo.com
> >> ..........................................................
> >> ASF - aheritier AT apache DOT org
> >> www.apache.org | maven.apache.org
> >> ...........................................................
> >>
> >
> >
> > --
> > ..........................................................
> > Arnaud HERITIER
> > ..........................................................
> > OCTO Technology - aheritier AT octo DOT com
> > www.octo.com | blog.octo.com
> > ..........................................................
> > ASF - aheritier AT apache DOT org
> > www.apache.org | maven.apache.org
> > ...........................................................
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> > For additional commands, e-mail: dev-help@maven.apache.org
> >
>
> Thanks,
>
> Jason
>
> ----------------------------------------------------------
> Jason van Zyl
> Founder and PMC Chair, Apache Maven
> jason at sonatype dot com
> ----------------------------------------------------------
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>


-- 
..........................................................
Arnaud HERITIER
..........................................................
OCTO Technology - aheritier AT octo DOT com
www.octo.com | blog.octo.com
..........................................................
ASF - aheritier AT apache DOT org
www.apache.org | maven.apache.org
...........................................................

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Mime
View raw message