Right now I usually find a pom.xml
file on the web that has a pom
packaging and copy and paste it to create my parent project. Then I used to run <
mvn archetype:create
has been deprecated in favor of mvn archetype:generate
, so just the name changed. There is an archetype for multi-module projects in the official repositories, so running this command yields the (minimalist) result:
[axe@gromp test]$ mvn archetype:generate
..
: remote -> pom-root (Root project archetype for creating multi module projects)
..
Choose a number: 109:
..
[axe@gromp test]$ tree
.
└── modules.test
└── pom.xml
1 directory, 1 file
[axe@gromp test]$ cat modules.test/pom.xml
4.0.0
com.example
modules.test
1.0-SNAPSHOT
pom
modules.test
So, basically you will have to create the folder structure and module descriptors (pom.xml files) yourself. Using a simple shell script or batch file will easily do this, if you require it more than once.