Reputation: 6852
I have a maven multimodule project
<modules>
<module>A</module>
<module>B</module>
<module>C</module>
</modules>
Module C depends on Module A. In this project structure can you let me know it is recommended to use package or install. I do not have any other requirement to share this project with other projects.
Upvotes: 2
Views: 139
Reputation: 3364
When launching a Maven command on multiple modules, if a dependency specified in one module is available as a project being built in the same command, Maven will use the output of the current build as dependency, instead of the JAR present in the local repository.
So it is not necessary to use install
to make the changes of a module available to modules depending on it, as long as these modules are always built together.
Upvotes: 3