Hi all,
When I use Gradle on a regular Java project that needs an external dependency, I add it to the dependencies block, as usual. Here I'm trying to use the RestTemplate from Spring Android:
repositories {
mavenCentral()
maven {
}
}
dependencies {
compile 'org.springframework.android:spring-android-rest-template:1.0.1.RELEASE'
compile files('libs/android-support-v4.jar')
}
When I run a 'gradle build', that works and downloads the proper dependencies. Unfortunately, they're not added to the Eclipse (or Android Studio) projects. When it comes to a normal Java project in Eclipse, to fix that I add the eclipse plugin:
apply plugin: 'eclipse'
and run:
> gradle cleanEclipse eclipse
which adds the dependencies as "referenced libraries". Doing that on an Android project messes it up, though, and also doesn't add the external libraries.
How do I fix the Eclipse project? Do I have to manually find the downloaded jar and add it as an external jar file?
Thanks,
Ken Kousen