CB-8143: Use the correct Android Gradle plugin for the installed Gradle version

This commit is contained in:
Ian Clelland 2014-12-10 10:07:05 -05:00
parent ffd14fe7d9
commit f953e6adb8

View File

@ -31,8 +31,18 @@ buildscript {
mavenCentral() mavenCentral()
} }
dependencies { // Switch the Android Gradle plugin version requirement depending on the
classpath 'com.android.tools.build:gradle:0.12.0+' // installed version of Gradle. This dependency is documented at
// http://tools.android.com/tech-docs/new-build-system/version-compatibility
// and https://issues.apache.org/jira/browse/CB-8143
if (gradle.gradleVersion >= "2.1") {
dependencies {
classpath 'com.android.tools.build:gradle:0.14.0+'
}
} else {
dependencies {
classpath 'com.android.tools.build:gradle:0.12.0+'
}
} }
} }