I am considering converting a set of inter-dependent modules to build with Gradle. These currently built with a mixture of Ant and the default eclipse builder. There is one ant script per project and a global ant script calls all of the others in (hopefully) the right order.

By implementing Gradle scripts I am hoping to have the global build script replaced by an "agenda" that is created at runtime that is inferred from which projects are checked out, which project is being built and what their dependencies are, etc. (I think this is similar to some behaviours of the Maven reactor)

The problem I am having with Gradle is that it seems mostly focused on hierarchical project layouts whereas Eclipse (which all of our developers use) only supports one directory full of projects. It seems that settings.gradle would have to be stored in the eclipse workspace root, which is not visible in the IDE. Is there a way around this?

Also, in this flat directory structure I would like some projects to configure others but I am not sure how to do this. For instance say I have:

WorkspaceRoot/
+ BuildCommon/
+ ModuleA/
+ ModuleB/

What is the best way to get gradle code in BuildCommon to configure gradle code in ModuleA and B? I was thinking that by declaring BuildCommon as a dependency of ModuleA and B I could apply (for example) the java plugin and some configuration from BuildCommon onto Modules A and B. But how would I reference A and B from BuildCommon. It seems that "subprojects" in Gradle only refers to subdirectories, is there a way to override this?

I would also add that (to me at least) it would be elegant if developers didn't have to checkout BuildCommon if they didn't intend to modify it. Instead it might be referenced though Ivy. However
this is not definate requirement.

Of course, I am not necessarily expecting Gradle to do all these things perfectly but I am interested in seeing how far it will go. I might even be fundamentally wrong about the way I am trying to build projects,
but I am sure you will let me know! ;)

Thanks,

Frank Wilson

Developer, Sidonis Ltd.

http://sidonis.com/








---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email


Reply via email to