##Composite Build Support in Buildship
We are currently working on a new Buildship release that will include support for
composite builds. This will allow Buildship to substitute dependencies and
de-duplicate project names across the whole workspace.
###What is a Composite Build?
The new composite build feature in Gradle will allow you to handle several distinct
Gradle builds as if they were one big multi-project build. This shortens the turnaround
when you need to work on several projects which are normally developed separately.
Letās assume you have written a Java library lib
, used by many of your applications.
You find a bug which only manifests itself in the special-app
. The current workflow
would be to change some code in lib
and install a snapshot into the local repository.
Then you would have to change the build script of special-app
to use that new
snapshot and check if the bug is actually fixed.
With composite builds you can tell Gradle to treat both of these projects as one.
This will let special-app
depend directly on the output of the lib
project.
###What does that mean for Buildship?
Buildship will be the first tool to benefit from the new composite build API. Once
implemented, Buildship will automatically replace external dependencies with project
dependencies. The matching will be done based on the projectās publications. So if
you have a project called lib
which publishes an artifact with the coordinates
my.org:lib
and you have a project special-app
which has a dependency
on my.org:lib
, then special-app
will depend on the lib
project if it is also in the Eclipse workspace.
Apart from dependency substitution, Buildship will also de-duplicate project names
across all Gradle builds in the workspace. So if you have two projects called foo
and bar
and both of them have a subproject called api
, then the corresponding Eclipse projects
will be called foo-api
and bar-api
.
As a nice side effect of this work, Buildship will also detect if the name of a Gradle
project has changed and rename the corresponding Eclipse project in the workspace.
###How can I give it a try?
The composite build feature is currently incubating. We are planning to release
it as part of Eclipse Neon. Your feedback is highly appreciated. It will help us
make this feature rock solid, so it can be activated by default.
We have set up a milestone update site from which you can consume the current state
of Buildship 2.0. So far we have implemented name de-duplication and project renaming.
We will follow up in this thread once dependency substitution is in place.