0
  • 在build.gradle(非app)中添加这一行
    buildscript {
        repositories {
            google()
            mavenCentral()
            maven { url "https://jitpack.io" }//在build.gradle(非app)中添加这一行
        }
        dependencies {
            classpath "com.android.tools.build:gradle:7.0.2"
    
            // NOTE: Do not place your application dependencies here; they belong
            // in the individual module build.gradle files
        }
    }
    然后,在settings.gradle中添加这一行
    dependencyResolutionManagement {
        repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
        repositories {
            google()
            mavenCentral()
            maven { url "https://jitpack.io" }//添加这一行
        }
    }
    rootProject.name = "TaobaoUnion"
    include ':app'
    
    1435499052144893953  评论     打赏       安德鲁
    • 网络不行吧

      1139423796017500160  评论     打赏       断点-含光君
      • 同一个文件夹里有两个repositories,都 添加一下吧。

        1153952789488054272  评论     打赏       拉大锯
        • imageinee  回复 @拉大锯
          都加了呢
          imageinee 2020-08-18 19:08   回复 1295631441174061056
        • 拉大锯  回复 @imageinee
          要么你翻墙,要么你自己下载下来打包自己依赖吧,方法不唯一。
          拉大锯 2020-08-18 19:19   回复 1153952789488054272
        • imageinee  回复 @拉大锯
          好的,谢谢!
          imageinee 2020-08-18 20:33   回复 1295631441174061056
      • 两个repositories都加一下吧,再同步一下,看看能否下载下来。

        1153952789488054272  评论     打赏       拉大锯
        相关问题
        幻影~ · 提问
        2024-04-13 20:13 7 2
        幻影~ · 找工作
        2024-04-07 10:44 11 2
        幻影~ · 问题
        2024-03-31 17:20 7 2
        TONYGFX · AOSP
        2024-03-28 17:11 4 2