- 在網(wǎng)上下載了一個(gè)android開源app低零,用Android studio打開后編譯時(shí)遇到下面的錯(cuò)誤
Failed to resolve: support-compat
// Top-level build file where you can add configuration options common to all sub-projects/modules.
apply from: "dependencies.gradle"
buildscript {
repositories {
jcenter()
maven { url 'https://maven.google.com' }
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.1.2'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
jcenter()
maven { url 'https://jitpack.io' }
maven { url 'https://maven.google.com' }
google()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
- 最終發(fā)現(xiàn)是classpath中的gradle版本不對(duì)甚淡,改成和本地其他項(xiàng)目一致的版本就對(duì)了
classpath 'com.android.tools.build:gradle:3.2.1'