Android studio Gradle项目同步已完成,但出现错误
我最近开始学习android studio,并在LinuxMint18上安装android studio,但遇到了这个问题。我的build.gradle文件包含以下代码Android studio Gradle项目同步已完成,但出现错误,android,android-gradle-plugin,Android,Android Gradle Plugin,我最近开始学习android studio,并在LinuxMint18上安装android studio,但遇到了这个问题。我的build.gradle文件包含以下代码 apply plugin: 'com.android.application' android { compileSdkVersion 25 buildToolsVersion "25.0.2" defaultConfig { applicationId "com.example.and
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion "25.0.2"
defaultConfig {
applicationId "com.example.android.justjava"
minSdkVersion 15
targetSdkVersion 25
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile 'com.android.support:appcompat-v7:25.+'
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.0', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'junit:junit:4.12'
}
只需替换您的
编译'com.android.support:appcompat-v7:25.+'
使用最新的依赖项,如
compile'com.android.support:appcompat-v7:25.3.1'
Gradle项目同步已完成,但有错误
您希望有人帮助您修复他不知道的错误吗?!请提供错误并解释此问题的含义!使用gradlew assemble--info获取更多细节这是一个很好的提示,因为使用+通配符从来都不是一个好主意,但它与问题无关。