Install parent POM without building Child modules

Mr.Eddart picture Mr.Eddart · Feb 29, 2012 · Viewed 44.1k times · Source

I have a parent POM in a Maven project, with this structure:

             parent
               |
        ---------------
        |             |
      child1       child2

I want to install the POM of the "parent" in the local REPO to allow child1 take some changes that I did in the dependencyManagement, but I cannot do a regular "clean install" because "child2" is broken and will not build.

Which is the proper way to do this with maven (other than going to the parent pom and commenting the "child2" module).

Answer

Guillaume Polet picture Guillaume Polet · Feb 29, 2012

Use the '-N' option in the mvn command.

From mvn -h:

-N,--non-recursive Do not recurse into sub-projects