Thank you Raphaël, And... would it be possible to add an antrun task somewhere which deletes the pom.xml file so that after generating the project from the archetype the task gets executed and deletes it?
I've tried adding such task to the "generate-sources" phase of the archetype's project pom.xml (not the archetype's pom.xml itself) and it never gets executed. I could execute it if I specify the "goal" parameter at "mvn archetype:generate -Dgoal=..." but then I'd have to specify that parameter explicitly, which I don't really want... can it be specified by default? Are there any other ways? Thank you again. Regards, Daniel. Raphaël wrote: > > Hi Daniel, > > The short answer is: nope. > > The long answer is: the archetype plugin generates maven a project. The > minmal maven project is just a pom.xml fle, Therefore, the archetype > plugin > always generates a pom. As the plugin uses archetype archives, the > archetypes must have at least a pom.xml file. > > Just drop a minimal pom.xml file in your archetype. > > Regards, > > Raphaël > > 2009/2/23 dfernandez <[email protected]> > >> >> Hello everyone, >> >> I would like to create a Maven archetype which creates a directory >> structure >> for some new projects, but as these projects will be documentation-only >> and >> no artifact will have to be generated from them, I don't want a pom.xml >> file >> to appear in the generated project at all (in fact they will be >> sub-projects >> of a bigger one, but I explicitly do not want to use the "module" >> management >> feature). >> >> The pom.xml seems to be impossible to filter (with an <exclude> clause), >> and >> if I directly remove it from the archetype, generating a project from it >> results in an error (for not finding pom.xml). Is there a way to avoid >> checking for this file, or at least a way of removing it automatically >> after >> creating the project? >> >> Regards, >> Daniel. >> >> -- >> View this message in context: >> http://www.nabble.com/Archetype-for-creating-projects-without-pom.-Is-it-possible--tp22161038p22161038.html >> Sent from the Maven - Users mailing list archive at Nabble.com. >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> > > -- View this message in context: http://www.nabble.com/Archetype-for-creating-projects-without-pom.-Is-it-possible--tp22161038p22169321.html Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
