Mercurial > public > develkit
comparison init.gradle @ 169:c4b7c8a11913
normalize spring security
author | Dave Smith <smith@nwoca.org> |
---|---|
date | Thu, 30 Jan 2014 02:39:30 +0000 |
parents | 7f023317034b |
children | e7824d2c2ca0 |
comparison
equal
deleted
inserted
replaced
168:7f023317034b | 169:c4b7c8a11913 |
---|---|
21 gradle.ext.hgRepositoryUrl = "" | 21 gradle.ext.hgRepositoryUrl = "" |
22 try { | 22 try { |
23 gradle.ext.hgRepositoryUrl = ("hg path".execute().text.split('=') ?: ['',''] )[1].trim() | 23 gradle.ext.hgRepositoryUrl = ("hg path".execute().text.split('=') ?: ['',''] )[1].trim() |
24 } catch (e) { } | 24 } catch (e) { } |
25 | 25 |
26 def springModuleTranslator = ['spring-transaction':'spring-tx'].withDefault { it } | 26 def springModuleTranslator = [ |
27 'spring-transaction' : 'spring-tx', | |
28 'spring-web-servlet' : 'spring-webmvc', | |
29 ].withDefault { it } | |
27 | 30 |
28 gradle.ext.normalizeSpring = { DependencyResolveDetails details -> | 31 gradle.ext.normalizeSpring = { DependencyResolveDetails details -> |
29 if (details.requested.group == 'org.springframework') { | 32 if (details.requested.group == 'org.springframework' && details.requested.name.startsWith ('org.springframework.' )) { |
30 if (details.requested.name.startsWith ('org.springframework.' )) { | 33 def shortName = springModuleTranslator[details.requested.name.replace('org.springframework.', 'spring-').replace('.','-')] |
31 def shortName = springModuleTranslator[details.requested.name.replace('org.springframework.', 'spring-').replace('.','-')] | 34 details.useTarget(group: 'org.springframework', name: shortName, version: details.requested.version) |
32 details.useTarget(group: 'org.springframework', name: shortName, version: details.requested.version) | 35 } |
33 } | 36 if (details.requested.group == 'org.springframework.security' && details.requested.name.startsWith ('org.springframework.' )) { |
34 } | 37 def shortName = springModuleTranslator[details.requested.name.replace('org.springframework.', 'spring-').replace('.','-')] |
35 } | 38 details.useTarget( "${details.requested.group}:$shortName:${details.requested.version}") |
39 } | |
40 } | |
41 | |
36 | 42 |
37 gradle.ext.branchName = System.getenv('bamboo_planRepository_branch') | 43 gradle.ext.branchName = System.getenv('bamboo_planRepository_branch') |
38 gradle.ext.branchStream = "" | 44 gradle.ext.branchStream = "" |
39 | 45 |
40 if (!gradle.branchName ) { | 46 if (!gradle.branchName ) { |