I had some issues with Gradle plugin 2.0.0-alpha6 and Gradle 2.10 and solved them by disabling Instant Run (as stated in Android Studio doesn't work fine with gradle 2.10 and gradle plugin 2.0.0-alpha5).
I then updated to gradle plugin 2.0.0-alpha7 without any issue
Today I updated Android Studio to the latest 2.0 Preview 8 version and I got the following error again:
Error:Could not find com.android.tools.build:gradle:2.0.0-alpha7. Searched in the following locations: https://repo1.maven.org/maven2/com/android/tools/build/gradle/2.0.0-alpha7/gradle-2.0.0-alpha7.pom https://repo1.maven.org/maven2/com/android/tools/build/gradle/2.0.0-alpha7/gradle-2.0.0-alpha7.jar
Now, I see by clicking on those links that the two files don't exist... but, I get the same error if I revert to gradle plugin 2.0.0-alpha5 or 2.0.0-alpha6, do it doesn't make much sense. Is the maven environment down, maybe?
That's quite frustrating. Now, I tried to check whether Instant Run is enabled and I got a surprise: it's disabled and I cannot enable-disable it anymore, since Android Studio doesn't seem to understand I'm building using gradle.
Probably that's because it can't find the Gradle files, therefore doesn't let me enable/disable features that depend on te gradle plugin version. So, I don't know what to do.
I already incremented the max heap size in my build.gradle file
dexOptions {
incremental true
javaMaxHeapSize "4g"
}
This is my full build.gradle file (except for some var settings I deleted from it): https://gist.github.com/MarKco/60f4ac63f7cafb783f3a