2010/10/8 Michael Sonntag <[email protected]>:
> I created an archetype that sets up a multi module project. After the
> creation of the new project, I want to run some other tasks, in my
> case there should be some classes generated from a database schema. I
> already created a Maven mojo as a wrapper for that generator, because
> one should also be able to call it independently. Regarding ease of
> use, the project creation and generation of files should be performed
> with one single command (so I don't want to do 'mvn
> archetype:generate[...]' and then 'cd newproject; mvn
> mygenerator:generate') and that's exactly my problem: how can I
> achieve that in a "clean" way? I already thought about creating
> another mojo that wraps the archetype and plugin calls, but that feels
> rather bumpy...
>
> What's the recommended way to do something like this?

Try "goals" parameter:
http://maven.apache.org/archetype/maven-archetype-plugin/generate-mojo.html#goals
However, since I've never tried it, I don't know if these goals are
executed before or after the project generation.

Antonio

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to