Reputation: 1185
My gradle dependency tree shows as below
+--- org.apache.lucene:lucene-core:3.6.2 -> 4.5.1
Since there are few changes in 4.5.1 which are not backward compatible , I want to force version 3.6.2 to be picked up.
how to stop gradle from pulling the latest version from the artifactory ?
Upvotes: 1
Views: 39
Reputation: 23677
You can use gradle's resolution strategy to override declared dependency versions:
configurations.all {
resolutionStrategy {
force 'org.apache.lucene:lucene-core:3.6.2'
}
}
Upvotes: 1