Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is maven.multiModuleProjectDirectory used for?

Tags:

java

maven

I've seen a lot of chatter regarding setting an env parameter maven.multiModuleProjectDirectory, both on SO and on Maven mailing lists, but I am having trouble understanding exactly what this setting does/is used for.

I've searched google, maven sites, docs, etc, but can't seem to find a reference that actually explains what this parameter is for, or how to leverage it.

Can anyone either explain it's purpose and/or point me to the documentation for it? In which version of maven was it introduced?

like image 264
Eric B. Avatar asked Apr 21 '15 16:04

Eric B.


1 Answers

The environment variable has been introduced in Maven 3.3.1 which is available from within the mvn script or mvn.cmd script. The intention is to find the start of a multi module structure where the .mvn location can be found.

This was introduced to make configuration within the project possible instead from outside.

Take a look into the Maven 3.3.1 release notes.

Update This variable is only used in the mvn script and is neither documented nor intended for public used (internal implementation detail). So I strongly recommend not to use it. Otherwise things might break in the future.

like image 68
khmarbaise Avatar answered Nov 01 '22 23:11

khmarbaise