maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Perham" <>
Subject RE: [m2] binding mojos to lifecycle
Date Tue, 31 Jan 2006 23:58:48 GMT
Look at it the other way.  You've told maven that you are interested in
having this plugin execute at some point during your lifecycle but you
haven't defined which GOAL to execute.  Remember a plugin can have N
goals.  Maven should use the goal's default phase if you don't specify
the <phase> element of the execution.

-----Original Message-----
From: Arik Kfir [] 
Sent: Tuesday, January 31, 2006 5:39 PM
To: Maven Users List
Subject: [m2] binding mojos to lifecycle


I have a small mojo which I want to bind to the 'process-classes'
phase. I've read which
indicates I should add a "@phase process-classes" to the class comment,
and I did:

 * @goal generate
 * @phase process-classes
 * @author arik
public class .... {

In the project that uses this plugin I declared:

          <!-- ... some configuration... -->

But the mojo isn't activated.

If, however, I add this to the invoking POM (inside the above <plugin>

everything works.

It looks like I'm missing something but I can't figure out what...I went
through all of the guides in the M2 site, but couldn't find a reason for
this. Isn't M2 supposed to bind my mojo automatically (due to the @phase

    Arik Kfir          

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message