問題描述
我將 android studio 從 3.3 更新到 3.4 版本,安裝并執行 ./gradlew lint
后出現下一個錯誤:
I updated android studio from 3.3 to 3.4 version and after install and do ./gradlew lint
I am getting the next error:
此版本中使用了已棄用的 Gradle 功能,使其與 Gradle 6.0 不兼容.
Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
然后我使用下一個命令來獲取更多詳細信息:
Then I use the next command to get more details:
./gradlwe build --warning-mode=all
我收到下一條消息:
無法應用插件 [id 'com.android.application']
Failed to apply plugin [id 'com.android.application']
支持的最低 Gradle 版本為 5.1.1.當前版本是 4.4.1.如果使用 gradle 包裝器,請嘗試編輯 .gradle/daemon/4.4.1/gradle/wrapper/gradle-wrapper.properties 中的 distributionUrl到 gradle-5.1.1-all.zip
Minimum supported Gradle version is 5.1.1. Current version is 4.4.1. If using the gradle wrapper, try editing the distributionUrl in .gradle/daemon/4.4.1/gradle/wrapper/gradle-wrapper.properties to gradle-5.1.1-all.zip
當我編輯我的 gradle-wrapper.properties 時,我看到更改已經完成,即distributionUrl
的版本已經是 gradle-5.1.1.-all.zip
And when I edited my gradle-wrapper.properties, I see that the changes were already done, I.E. the version of the distributionUrl
already was gradle-5.1.1.-all.zip
知道如何解決這個問題嗎?
Any idea that how can resolve this?
推薦答案
最后,我能夠解決這個問題,刪除 ~/.gradle/wrapper/dists
中最舊版本的文件夾并離開只有 gradle-5.1.1-all
Finally, I was able to solve this dropping the folders of the oldest version in ~/.gradle/wrapper/dists
and leave only the gradle-5.1.1-all
這篇關于錯誤“支持的最低 Gradle 版本為 5.1.1.當前版本是 4.4.1"更新 android studio 后的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!