You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Andrew Robinson <an...@gmail.com> on 2008/04/18 20:24:12 UTC
Customization during custom archetype execution?
I have never written an archetype, so please excuse my ignorance. I
would like to make a dynamic archetype. What I mean by this is to be
able to have it ask users (via command prompts or just via system
properties if that is not possible) what they want and be able to
change the archetype on the fly.
What I was envisioning:
mvn archetype:create \
-DarchetypeGroupId=org.apache.myfaces.buildtools \
-DarchetypeArtifactId=myfaces-archetype-dynamic \
-DarchetypeVersion=1.0 \
-DgroupId=<my.groupid> \
-DartifactId=<my-artifactId>
Hello user, please choose a JSF implementation:
1. Mojarra
2. MyFaces
Include Tomahawk? (y/N):
Choose a renderkit:
1. Core
2. Tobago
3. Trinidad
Choose a view handler:
1. JSP
2. Facelets
Choose a data provider framework:
1. None
2. Seam
3. Orchestra
etc.
Is there any way to do this with the achetype plugin or do I have to
write my own Maven Plugin that works like the archetype plugin that I
am able to run custom Java during execution? If I can write out a base
structure and then have a way to run a custom mojo after the archetype
is run to be able to add resources and modify the pom.xml, that would
probably work as well?
Any advice?
Thanks,
Andrew
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org