我試圖在build.gradle(Module.app)
添加新的依賴關係後生成項目,但得到以下錯誤。不知道我在這裏做錯了什麼。Gradle同步失敗:無法找到方法編譯()的參數
依賴嘗試添加:com.loopj.android:android-async-http:1.4.9
Gradle sync failed: Could not find method complie() for arguments [com.loopj.android:android-async-http:1.4.9] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
Consult IDE log for more details (Help | Show Log)
這是我的build.gradle
文件
apply plugin: 'com.android.application'
android {
compileSdkVersion 25
buildToolsVersion '25.0.2'
defaultConfig {
applicationId "com.londonappbrewery.climapm"
minSdkVersion 16
targetSdkVersion 25
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:25.3.1'
complie 'com.loopj.android:android-async-http:1.4.9'
}
拼寫錯誤的'compile'不complie –