Gives an error: Plugin is too old, please update to a more recent version, or set ANDROID_DAILY_OVERRIDE envrinment variable to...

As I understand it, you need to update Gradle , but for me it was a black box, as with the help of the studio I did not try to fix it, and nothing helped.

Gradle himself:

 apply plugin: 'com.android.application' android { compileSdkVersion 23 buildToolsVersion "23.0.3" defaultConfig { applicationId "com.asgard.power" minSdkVersion 15 targetSdkVersion 23 versionCode 1 versionName "1.0" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) testCompile 'junit:junit:4.12' compile 'com.android.support:appcompat-v7:24.0.0-alpha1' compile 'com.android.support:design:24.0.0-alpha1' compile 'com.android.support:recyclerview-v7:24.0.0-alpha1' compile 'com.android.support:cardview-v7:24.0.0-alpha1' } 

How to deal with this?

  • There is usually in the error message itself there is such a link that “update” - click on it and the studio will do everything by itself - pavlofff
  • I tried, it did not change anything. - Silento
  • Thanks for trying to help, found a solution in this topic: www.stackoverflow.com/questions/517263/… - Silento

1 answer 1

Most likely you need in the file gradle-wrapper.properties

change distributionUrl string

 distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip 
  • I don’t drive in at all, how it works, honestly. It would allow time to sit down and figure it out - but it’s not there, so I’m writing here. Tell me which line to change it to? - Silento
  • And now what have you got there? - Roman Novoselov
  • buildscript {repositories {jcenter ()} dependencies {classpath 'com.android.tools.build:gradle:2.1.0'}} Only I did not touch the gradle - wrapper.properties, but updated the studio, then clicked the fix - and he suggested to me update gradle - Silento
  • Now look what you have in gradle-wrapper.properties - Roman Novoselov
  • Gaddle updated, most likely you need to set a distributionUrl for it - Roman Novoselov