0

Suppose we have a multimodule project:

<modules>
  <module>first</module>
  <module>second</module>
</modules>

where second depends on first through dependencies.

If I run mvn cleanpackage, does maven or reactor will put any of the modules to local repo anyway?

glaz666
  • 8,707
  • 19
  • 56
  • 75

1 Answers1

0

The answer is no.

Here are the maven lifecycle phases

As you can see, package comes before install, so install wont be executed - nothing will go to your local repo, unless it was there already.

vikingsteve
  • 38,481
  • 23
  • 112
  • 156
  • Actually I doubt. How is jar dependency then found to be added to final package or at least for running compile phase for `second` module? – glaz666 Jun 28 '13 at 11:14
  • I suspect if you run `package` on the second module you'll get an error like *Could not resolve dependencies for project* - have you tried it out? – vikingsteve Jun 28 '13 at 11:19