找不到 io.fabric.tools:gradle

Could not find io.fabric.tools:gradle

我正在遵循面料的官方说明

https://www.fabric.io/kits/android/crashlytics/install

这是我的 gradle.build 文件

apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'io.fabric'

buildscript {
ext.kotlin_version = '1.1.51'
repositories {
    jcenter()
    mavenCentral()
    maven {
        url 'https://maven.google.com'
    }
}
dependencies {
...
    classpath 'io.fabric.tools:gradle:1.24.3'

    }
}

repositories {
    jcenter()
    mavenCentral()
    maven { url "https://jitpack.io" }
    maven {
        url 'https://maven.google.com'
    }
    maven { url 'https://maven.fabric.io/public' }

}

android {

compileSdkVersion 22

buildToolsVersion '25.0.3'
defaultConfig {
    ....
}

}
dependencies {
......
   compile('com.crashlytics.sdk.android:crashlytics:2.7.0@aar') {
    transitive = true
  }
}

apply plugin: 'com.google.gms.google-services'

但是当我尝试同步我的项目时,它说找不到 io.fabric.tools:gradle:1.24.3 在以下位置搜索:

Error:Could not find io.fabric.tools:gradle:1.24.3.
Searched in the following locations:

    file:/home/dev-00/soft/android-studio-3.0.0/android-studio/gradle/m2repository/io/fabric/tools/gradle/1.24.3/gradle-1.24.3.pom
    file:/home/dev-00/soft/android-studio-3.0.0/android-studio/gradle/m2repository/io/fabric/tools/gradle/1.24.3/gradle-1.24.3.jar
    https://jcenter.bintray.com/io/fabric/tools/gradle/1.24.3/gradle-1.24.3.pom
    https://jcenter.bintray.com/io/fabric/tools/gradle/1.24.3/gradle-1.24.3.jar
 ...    Required by:
    project :

在您的 buildscript 块中,您还必须添加 fabric 存储库。

  buildscript {
      repositories {
         //... jcenter(), google()...
         maven { url 'https://maven.fabric.io/public' }
      }
   }

  dependencies {
     //......
  }
}