I have a multi-project build that makes extensive use of sub-projects in order to make dependencies between them explicit (by means of dependsOn
- the sub-projects act as layers).
If it comes to publishing I want to roll up all the sub-project artifacts into the artifact of the main project (jar), and collect all their libraryDependencies. In other words, I want to publish as if there would be no sub-projects, just a single root project containing all my code (i.e. no ueber-jar). The sub-projects are only there to break up the compilation into smaller scopes with enforced dependency structure, they are not supposed to be distributed separately.
What is the best way to achieve that?