I am not able to find out what is the exact issue when I add the dependencies.
dependencies {
compile 'com.github.jetradarmobile:android-snowfall:1.1.2'
}
I get the above error
my Gradle(Project)
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.1'
}
}
allprojects {
repositories {
jcenter() {
maven { url "https://jitpack.io" }
}
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "24.0.3"
defaultConfig {
applicationId "com.animationbook.animationbook"
minSdkVersion 15
targetSdkVersion 24
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 fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:24.2.1'
debugCompile 'junit:junit:4.12'
compile 'com.github.moondroid.coverflow:library:1.0'
compile 'com.github.jetradarmobile:android-snowfall:1.1.2'
}
How can the error be solved?
It's happen because your dependency com.github.jetradarmobile:android-snowfall:1.1.2
has compileSdkVersion 25
, buildToolsVersion "25.0.2"
& com.android.support:support-compat:25.0.1
.
So you need to change com.android.support:appcompat-v7:24.2.1
to com.android.support:appcompat-v7:25.1.0
, buildToolsVersion
to 25.0.1
and com.android.support:design:25.1.0
.
If you don't want to change your buildToolsVersion
than you can use module of it and change modules buildToolsVersion
.
change the buildToolsVersion to 25.0.1
and add dependency compile 'com.android.support:design:25.1.0'
And also change compile 'com.android.support:appcompat-v7:24.2.1'
to compile 'com.android.support:appcompat-v7:25.1.0'
I had the same problem and what I did to solve it was Update "Google Repository" and "Android Support repository" in the Android SDK Manager.
I hope it helps!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With