I just spend some time and failed trying to migrate an existing android studio project from gradle 1.8 to gradle 1.9 final ( which was released yesterday 19th Nov ).
I read most of the other gradle related posts here but none worked for me. here a list of what I've tried so far:
- ./gradle/wrapper/gradle-wrapper.properties changed distributionUrl to gradle-1.9-all.zip
- Rebuild Project
- in android-studio: Tools -> Android -> Synch Project with Gradle Files
- running command
gradle wrapper
in project dir to update the wrapper
-
build.gradle file
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:0.6.+'
}
}
apply plugin: 'android'
repositories {
mavenCentral()
}
android {
compileSdkVersion 19
buildToolsVersion "19.0.0"
defaultConfig {
minSdkVersion 14
targetSdkVersion 16
}
}
dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
}
dependencies {
compile 'com.android.support:appcompat-v7:18.0.0'
}
all ended with the "need gradle 1.8, change your gradle-wrapper.properties to gradle-1.8-all.zip" error message.