Gradle Multi-Project Builds

From NovaOrdis Knowledge Base
Revision as of 01:33, 22 October 2020 by Ovidiu (talk | contribs) (→‎Project Dependencies)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Internal

TODEPLETE

Gradle Multi-Project Builds TODEPLETE

Overview

Sub-projects can depend on each other in the context of a multi-project build.

Inter-Project Dependencies

Projects that are part of the same multi-project build may be related to each other via two kind of dependencies: project dependencies and task dependencies.

Project Dependencies

https://docs.gradle.org/current/userguide/declaring_dependencies.html#sub:project_dependencies

Projects (modules) can define dependencies between each other to reuse code. A project dependency is declared with the following syntax in build.gradle:

dependencies {
  implementation project(':shared')
}

Task Dependencies

Task Dependencies