在为 Android 开发 Ionic 3应用程序时,我突然出现了以下错误。
Could not find org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.60-eap-25
我们有一个来自 Android Studio 给你的解决方案,但是在我用下面的代码修改 build.gradle 之后,我仍然得到了这个错误。
buildscript {
repositories {
...
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
}
}
allprojects {
repositories {
...
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
}
}
在我更新了 Cordova 并添加了上述解决方案之后,build.gradle 文件看起来如下所示。
buildscript {
repositories {
google()
jcenter()
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
}
dependencies {
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
classpath 'com.android.tools.build:gradle:3.3.0'
}
}
allprojects {
repositories {
google()
jcenter()
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
}
//This replaces project.properties w.r.t. build settings
project.ext {
defaultBuildToolsVersion="28.0.3" //String
defaultMinSdkVersion=19 //Integer - Minimum requirement is Android 4.4
defaultTargetSdkVersion=28 //Integer - We ALWAYS target the latest by default
defaultCompileSdkVersion=28 //Integer - We ALWAYS compile with the latest by default
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
还是同样的错误。