7
我知道這是一個重複的問題,但我試過無數的代碼,但解決不了錯誤運行時間gradle這個例外
Error:Execution failed for task ':app:transformClassesWithJarMergingForDebug'. com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: android/support/v4/accessibilityservice/AccessibilityServiceInfoCompat$AccessibilityServiceInfoVersionImpl.class
gradle這個文件
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig {
applicationId "com.cwish"
minSdkVersion 16
targetSdkVersion 23
versionCode 1
versionName "1.0"
multiDexEnabled true
}
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:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.google.code.gson:gson:2.6.2'
compile 'com.squareup.retrofit2:retrofit:2.1.0'
compile 'com.squareup.retrofit2:converter-gson:2.1.0'
compile 'com.android.support:recyclerview-v7:+'
compile 'com.android.support:recyclerview-v7:[email protected]'
compile 'com.daimajia.numberprogressbar:library:[email protected]'
compile 'com.google.android.gms:play-services:8.3.0'
compile 'com.koushikdutta.ion:ion:2.+'
}
你可以添加你的gradle文件嗎? – Zarwan
我在 –
@ErKishorMaharjan上面添加了gradle文件,您正在使用support:recyclerview-v7兩次。剛剛刪除編譯''com.android.support:recyclerview-v7:23.1.0 @ aar''從你的gradle它將解決你的問題:) –