Android.support Libraries Not Compatible Together After Updation
I just updated my gradle plugin and then got warnings telling me to update some of my implementations. I just upgraded both com.android.support:appcompat and com.android.suppo
Solution 1:
Put something like this in your root project:
Map<String,String> versionOverrides = [
'com.android.support:support-v7' : '27.1.1'
...
]
def overrideDependencies = { Project project ->
project.configurations.all {
// See https://docs.gradle.org/current/dsl/org.gradle.api.artifacts.ResolutionStrategy.html
resolutionStrategy {
eachDependency { DependencyResolveDetails details ->
String overrideVersion = versionOverrides.get(details.requested.group + ":" + details.requested.name)
if (overrideVersion != null && details.requested.version != overrideVersion) {
logger.debug("Overriding dependency ${details.requested.group}:${details.requested.name} " +
"version ${details.requested.version} --> $overrideVersion")
details.useVersion overrideVersion
}
}
}
}
}
subprojects { project ->
overrideDependencies(project)
}
Post a Comment for "Android.support Libraries Not Compatible Together After Updation"