android studio 更改gradle版本方法(备忘)

如果出现类似以下:

Your build is currently configured to use Java 17.0.11 and Gradle 6.1.1.

或者类似:

Failed to calculate the value of task ':app:compileDebugJavaWithJavac' property 'options.generatedSo

消息时需要修改gradle版本,升级和降级也适用。

gradle可下载版本地址:

http://mirrors.cloud.tencent.com/gradle/

原位置:

复制代码
https://services.gradle.org/distributions/distributions/gradle-5.4.1-all.zip

这个链接已经无法访问了,无法下载文件。

修改该网址位置:

android-gradle scripts-gradle-wrapper.properties内

如下图:

gradle可下载版本地址:

http://mirrors.cloud.tencent.com/gradle/fl

截图:

相关推荐
Digitally23 分钟前
如何通过 5 种有效方法同步 Android 和 Mac
android·macos
小蕾Java28 分钟前
PyCharm 软件使用各种问题 ,解决教程
ide·python·pycharm
行墨2 小时前
Jetpack Compose 深入浅出(二)——基础组件Text
android
雨白4 小时前
深入理解协程的运作机制 —— 调度、挂起与性能
android·kotlin
沐怡旸4 小时前
【Android】Android系统体系结构
android
namehu4 小时前
React Native 应用性能分析与优化不完全指南
android·react native·ios
xqlily5 小时前
Kotlin:现代编程语言的革新者
android·开发语言·kotlin
HelloBan5 小时前
如何正确去掉SeekBar的Thumb和按压效果
android
木易 士心5 小时前
Android EventBus 源码解析:设计模式、原理与实现
android
ClassOps5 小时前
源码阅读 LeakCanary
android