On 18/06/2011, at 1:13 AM, Gerwin Jansen wrote:
> I have the following use case:
> My multi-project setup needs to support subversion partial check-out.
> This means that my subprojects are sometimes part of the check-out and
> sometimes not. So a subproject is sometimes a project dependency and
> sometimes an artifact dependency.
>
> I tried to write a method/function to achieve this result:
> def createDependency(projectname)
> {
> if(exists("components/" + projectname)
> {
> dependencies { compile project(projectname) }
> }
> else
> {
> dependencies { compile "com.cordys:" + projectname + ":SNAPSHOT" }
> }
> }
>
> But I'm getting stuck with this. After diving more deeply in Gradle I
> feel like adding a ProjectEvaluationListener. But this is completely
> new terrain for me.
> Does anyone know the solution? Or a solution direction?
> Any help is highly appreciated.
What problems did you have?
This is a suitable approach, but you are also going to need some code in
settings.groovy to only include the subprojects that were checked out.
--
Luke Daley
Principal Engineer, Gradleware
http://gradleware.com
Please vote Gradle for JAX Awards ยป http://vote.jax-awards.com
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email