我正在尝试将Fabric添加到我的项目中,但是在fabric.io上没有提供API密钥或机密的地方?
可以吗?
apply plugin: 'io.fabric'
答案 0 :(得分:0)
`Please add maven and dependencies in project-level build.gradle
buildscript {
repositories {
// ...
// Add repository
maven {
url 'https://maven.fabric.io/public'
}
}
dependencies {
// ...
// Check for v3.1.2 or higher
classpath 'com.google.gms.google-services:4.2.0'
// Add dependency
classpath 'io.fabric.tools:gradle:1.28.1'
}
}
allprojects {
// ...
repositories {
// ...
// Check that you have the following line (if not, add it):
google() // Google's Maven repository
// ...
}
}
在您的应用程序级别build.gradle中,添加插件和依赖项: 应用插件:“ io.fabric”
依赖项{ // ...
// Check for v11.4.2 or higher
implementation 'com.google.firebase:firebase-core:16.0.8'
// Add dependency
implementation 'com.crashlytics.sdk.android:crashlytics:2.10.0'
} 请点击下面的链接https://firebase.google.com/docs/crashlytics/get-started?platform=android。将项目添加到Firebase控制台。