0
down vote
favorite
I have a user defined sourcesets (mysourceset) in project A, and in project B want to depend on its output. I tried
testCompile project(path: ‘:A’, configuration: ‘mysourcesetCompile’) but no luck.
Also tried creating a configuration in project A and using it in project B as follows. testCompile project(’:A’).configurations.myconfig
also no luck!
I tried project(’:A’).files(’.’) which worked at the end. But looking for a better solution. Uploaded a mini sample project to: https://github.com/ghamarian/gradleproblem
Your first attempt at using configurations is a much better solution than using evaluationDependsOn and depending on internals of other projects. You just missed a couple things.
Project A needs to define the configuration, but it also needs to add an appropriate artifact to it.