我刚把我的安卓项目的构建系统从Groovy迁移到了Kotlin DSL。在迁移时,我无法解决build.gradle.kts中的firebaseAppDistribution {..}。
FAD插件已经被应用,并且类路径也已经设置好了。
plugins {
id("com.android.application")
//id("com.google.firebase.appdistribution") //I've tried it here but "Plugin not found"
kotlin("android")
kotlin("android.extensions")
kotlin("kapt")
id("com.google.gms.google-services")
}
apply(plugin = "com.google.firebase.appdistribution")
buildscript {
repositories {
google()
}
dependencies {
classpath("com.google.firebase:firebase-appdistribution-gradle:1.3.1")
}
}
. .
productFlavors {
create("dev") {
firebaseAppDistribution {
serviceCredentialsFile = "xxx.json"
groups = "xx"
}
}
}
. .
**Unresolved reference: firebaseAppDistribution**
我该如何修复它?