maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Olivier DAUMAS <>
Subject Maven Archetype Generate using my own property
Date Mon, 25 Mar 2013 10:44:27 GMT

I am trying to generate artefact from maven archetype and I would like to
generate some basic java classes depending on parameters given in the
command line.
call mvn archetype:generate -B -X -DarchetypeGroupId=myarchetypegroupid
-DarchetypeArtifactId=myarchetype -DarchetypeVersion=1.0-SNAPSHOT
-DgroupId=mygroupid -DartifactId=myartefact -Dversion=myversion --Dmodulename=%MODULE%

Typically I need to be able to pass extra parameter that velocity will used
to filter some of the file contained into the archetype and will lead to
final java object with specific names.
But only some of them like groupid and artefactid are available in velocity

public class public class ${className}Handler{
private static final Logger s_logger = LoggerFactory


Do you have any idea how to manage passing my own variables ?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message