Gradle failed to sync: failed to update Android plugin to version 2.0.0,

I recently updated Android Studio to version 2.0. I work on a partial course, and I need to work on a project. When gradle tried to create a project, a dialog box appeared asking for an update to the android studio gradle plugin. When I clicked the update, I got an error, which is in the header.

My gradle files look like this:

Gradle Wrap:

#Wed Sep 30 11:56:02 PDT 2015
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=http\://services.gradle.org/distributions/gradle-2.2-bin.zip

Gradle module:

apply plugin: 'com.android.application'
apply plugin: 'android-apt'

android {
  compileSdkVersion 23
  buildToolsVersion "23.0.1"

  defaultConfig {
    applicationId "com.example.sam_chordas.stockhawk"
    minSdkVersion 15
    targetSdkVersion 23
    versionCode 1
    versionName "1.0"
  }
  buildTypes {
    release {
      minifyEnabled false
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
  }
}

repositories {
  maven { url "https://jitpack.io" }
}

dependencies {

  compile 'com.google.android.gms:play-services-gcm:8.4.0'
  compile 'com.squareup.okhttp:okhttp:2.5.0'
  apt 'net.simonvt.schematic:schematic-compiler:0.6.3'
  compile 'net.simonvt.schematic:schematic:0.6.3'
  compile 'com.melnykov:floatingactionbutton:1.2.0'
  compile 'com.android.support:design:23.1.1'
  compile('com.github.afollestad.material-dialogs:core:0.8.5.7@aar') {
    transitive = true
  }
}

Gradle Project:

// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
  repositories {
    jcenter()
    mavenCentral()
  }
  dependencies {
    classpath 'com.neenbedankt.gradle.plugins:android-apt:1.2'
    classpath 'com.google.gms:google-services:1.4.0-beta3'


    // NOTE: Do not place your application dependencies here; they belong
    // in the individual module build.gradle files
  }
}

allprojects {
  repositories {
    jcenter()
  }
}

I cannot work on a project since I cannot build it. If someone had such problems and this is fixed, I would really appreciate help, since I spend a lot of time. I must mention that this is a Windows 7 machine.

thank

+4
1

1) compileSdkVersion = 23, , 23. com.android.support:design:23.3.0 . , , .

2) gradle Android build. gradle/gradle-wrapper.properties:

distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip

3) "23.0.2". build.gradle .

4) Google Play , Android build. , -, , . build.gradle:

classpath 'com.google.gms:google-services:2.0.0'

5) Android!

classpath 'com.android.tools.build:gradle:2.0.0'

6) apt . - 1.8.

classpath 'com.neenbedankt.gradle.plugins:android-apt:1.8'

7) OkHttp . - 2.7.5 3.2.0.

compile 'com.squareup.okhttp:okhttp:2.7.5'
+3

All Articles