简体   繁体   中英

Unable to sync gradle files - Android Studio

Can anyone please give me solution as I have download fresh Bumblebee Android studio and trying to create a sample project but it is unable to sync grade files and showing following error- 在此处输入图像描述

I have following gradle versions of wrapper.properties and plugin:

wrapper.properties

distributionBase=GRADLE_USER_HOME
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME

app.gradle file:

plugins {
    id 'com.android.application' version '7.1.2' apply false
    id 'com.android.library' version '7.1.2' apply false
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
  1. Close Android Studio if it is being opened.
  2. Delete cache in these folders:

C:\Users\xxxxx\.gradle\caches

C:\Users\xxxxx\.android\build-cache

C:\Users\xxxxx\.android\cache

androidstudio -> 文件 -> 使缓存无效并重新启动。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM