'How to build several projects with dependencies

I have workspace with n projects. I want to use ant to build all the projects with one command. The projects are depend on each other

For example project A depends on project B, so I want B to compile first When I compile project An I need to use B's project classpath. The dependencies between the projects are represented in a ivy.xml file

The main challenge is that I have my own repository where all those projects have artifacts, and using the example I just gave Project A compiles against the B project coming from my the repository and not Against the B project that just was compiled.

I use CI process and I don't want to publish any project to my repository before all of them compiled and the the the QA tests was passed

What is the best practice build several projects with dependencies using ant?



Solution 1:[1]

You can spend a significant amount of time fighting ant and ivy in order to achieve what you want, or you could just use Maven or Gradle which will handle all of this for you automatically.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 AlBlue