Ok, sounds like I will have to write my own task to generate the .classpath
file then.  I put multiple build targets in the same Eclipse project all the
time, so I'm pretty comfortable knowing there won't be issues with it.  Do
you know how I'd print the transitive dependencies of the project?  Right
now I've only figured out how to get the first-level dependencies.

task printClasspath << {
  cp = [] as Set
  subprojects.each {
    it.configurations.runtime.allDependencies.each {
      if
(it.class.simpleName.equals('DefaultExternalModuleDependency_Decorated')) {
        lib = '/home/' + System.getenv()['USER'] + '/.gradle/cache/' +
it.group + '/' + it.name + '/jars/' + it.name + '-' + it.version + '.jar'
        source = lib.replace('jars', 'sources')
        cp.add('  <classpathentry sourcepath="' + source + '" kind="lib"
path="' + lib + '" exported="true"/>')
      }
    }
  }
  cp.each { println it }
}
-- 
View this message in context: 
http://gradle.1045684.n5.nabble.com/How-to-use-the-Eclipse-plugin-with-a-multi-project-build-tp3370505p3370586.html
Sent from the gradle-user mailing list archive at Nabble.com.

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

    http://xircles.codehaus.org/manage_email


Reply via email to