And *that* was exactly what I needed. Thank you very much for your help. It turns out the lifecycle.xml was fine, but I needed *both* a LifecycleMapping component *and* a Lifecycle component. I had discovered examples with each separately on the web, but this is the first example I've seen with both -- and that's what is needed for everything to work. The working set of components is below.
Note that the example you pointed me to has some duplication that is (conveniently) not needed: you can delete the configuration from the LifecycleMapping. In an expression of thanks, I'm willing to write up a replacement for the now out-of-date page at http://www.sonatype.com/books/mvnref-book/reference/writing-plugins-sect-plugins-lifecycle.html; does anyone know how such a thing would be contributed? Thanks again! John <component-set> <components> <component> <role>org.apache.maven.lifecycle.mapping.LifecycleMapping</role> <role-hint>lenskit</role-hint> <implementation> org.apache.maven.lifecycle.mapping.DefaultLifecycleMapping </implementation> </component> <component> <role>org.apache.maven.lifecycle.Lifecycle</role> <implementation>org.apache.maven.lifecycle.Lifecycle</implementation> <role-hint>lenskit</role-hint> <configuration> <id>lenskit</id> <phases> <phase>get-data</phase> <phase>analyze</phase> <phase>eval</phase> </phases> <default-phases> <get-data>org.riedl:hello-lenskit-plugin:greet</get-data> <analyze>org.riedl:hello-lenskit-plugin:greet</analyze> <eval>org.riedl:hello-lenskit-plugin:greet</eval> </default-phases> </configuration> </component> </components> </component-set> On Sun, Sep 16, 2012 at 7:42 AM, Benson Margulies <bimargul...@gmail.com> wrote: > We happen to have an example of this in stock, recently minted. > > https://svn.apache.org/repos/asf/maven/plugins/trunk/maven-scm-publish-plugin > > That is, this is a plugin with a custom lifecycle definition and custom > phases. > > > > On Sun, Sep 16, 2012 at 12:00 AM, Barrie Treloar <baerr...@gmail.com> wrote: >> On Sun, Sep 16, 2012 at 7:06 AM, John Riedl <ri...@umn.edu> wrote: >>> Baptiste: >>> >>> Thanks for the answer. You're certainly right about needing the >>> extensions true line, and I do have that in my pom (below). Note that >>> the error message I'm getting gives a complete list of all lifecycle >>> phases that are legal, and that the list does not include any of the >>> phases I've tried to define. Note also that in the pom I ask for >>> packaging lenskit. If I change that to something else, like "foo", I >>> get an error that foo is an unknown lifecycle. So: it seems that >>> maven is picking up the lifecycle, but NOT changing its list of >>> built-in phases. >> >> Doing this is advanced Maven stuff. >> It involves some understanding of plexus which is not well documented. >> >> I'm not sure whether the Maven books at >> http://maven.apache.org/articles.html go into that level of details. >> >> I'm sure there are examples out there of how to do this, but I can't >> think of any of the top of my head. >> >> Looking at your stack overflow page I see spaces inside the content of >> your tags, dont know if that is causing problems. >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org >> For additional commands, e-mail: users-h...@maven.apache.org >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org