使用了最新版本Android Studio,Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
完整报错如下:
An exception occurred applying plugin request [id: ‘com.android.application’]
Failed to apply plugin ‘com.android.internal.application’.
Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
You can try some of the following options:
– changing the IDE settings.
– changing the JAVA_HOME environment variable.
– changingorg.gradle.java.home
ingradle.properties
.
解决方法
File -> Settings -> Build,Execution,Deployment -> Build Tools -> Gradle
分享一个鸿蒙开发教程