This works, thanks! In my case I needed to remove the classifier, so the syntax ended up like:
configurations.all {
resolutionStrategy.eachDependency { DependencyResolveDetails details ->
if (details.requested.module.toString() == "commons-beanutils:commons-beanutils") {
details.artifactSelection{
it.selectArtifact(DependencyArtifact.DEFAULT_TYPE, null, null)
}
}
}
}