suppose the following project. the master project is a multi-project, however every part of the larger project can be developed individually or mixed in:
/master/build.gradle
/m1/build.gradle
/m2/build.gradle
/m3/build.gradle
suppose m3
uses m2
and m2
uses m1
( m1 <- m2 <- m3 )
the presence of m2
is optional a multi-project with the following layout also reasonable
/master/build.gradle
/m1/build.gradle
/m3/build.gradle
but in this case m2
would be pulled in from the artifact repository which is fine...however m1
was a transitive dependency of m2
which is good, but how can i tell gradle to use the local version of m1
instead of the baked artifact?
I'm stuck with this, every place i have access to override these thing gradle gives me "just" ModuleVersionSelector
level access, how can i add a DefaultProjectDependency
according to the downloaded artifact transitive dependencies?
i may have an alternative if i can access the full dependency graph of the archived artifacts, and put in some overrides/excludes.
EDIT:
the best i've come up with is using a filter using resolutionStrategy, i've created an example by further developing the 'elastic-deps' project