comparison init20.gradle @ 231:ce34e62224cf

update set dependencyLock plugin to also lock transitives. provide way of overriding common version
author smith@nwoca.org
date Thu, 08 Sep 2016 17:10:43 +0100
parents e902c107f5db
children 47535c8358ce
comparison
equal deleted inserted replaced
230:e902c107f5db 231:ce34e62224cf
229 229
230 apply plugin: nebula.plugin.dependencylock.DependencyLockPlugin 230 apply plugin: nebula.plugin.dependencylock.DependencyLockPlugin
231 231
232 dependencyLock { 232 dependencyLock {
233 globalLockFile = gradle.branch.isRelease() ? 'release.lock' : 'global.lock' 233 globalLockFile = gradle.branch.isRelease() ? 'release.lock' : 'global.lock'
234 includeTransitives = true
234 } 235 }
235 236
236 configurations.all { 237 configurations.all {
237 resolutionStrategy.eachDependency { DependencyResolveDetails details -> 238 resolutionStrategy.eachDependency { DependencyResolveDetails details ->
238 if (details.requested.group == 'org.ssdt_ohio' && !details.requested.version ) { 239 if (details.requested.group == 'org.ssdt_ohio' && !details.requested.version ) {
239 details.useVersion( "latest.${gradle.branch.defaultDependencyStatus}" ) 240 details.useVersion( "latest.${gradle.branch.defaultDependencyStatus}" )
240 } 241 }
241 if (details.requested.version == 'default') { 242 if (details.requested.version == 'default') {
242 details.useVersion("latest.${gradle.branch.defaultDependencyStatus}" ) 243 details.useVersion("latest.${gradle.branch.defaultDependencyStatus}" )
244 }
245 if (project.hasProperty("overrideCommon")) {
246 if (details.requested.group == 'org.ssdt_ohio' && details.requested.name.contains('ssdt.common.')) {
247 details.useVersion(project.overrideCommon)
248 }
243 } 249 }
244 } 250 }
245 } 251 }
246 252
247 task cleanLocal(description: "removes all artifacts from developer's local repository") << { 253 task cleanLocal(description: "removes all artifacts from developer's local repository") << {