I have project like
module1
module2
module3
submodule1
src
main
java
resources
child1
child2
module4
When I run mvn clean install on the project all top and submodules builds. But I want maven not to execute child1, child2. How I can do that. I found that using profiles I can do that. But how? Can I do something in submodule1 pom so that child1, child2 exclude from the maven phases ?