80 lines
1.7 KiB
Groovy
80 lines
1.7 KiB
Groovy
rootProject.name = 'spring-security'
|
|
|
|
rootProject.children.each {project ->
|
|
//assert project.projectDir.isDirectory()
|
|
//assert project.buildFile.isFile()
|
|
}
|
|
|
|
def String[] modules = [
|
|
'core',
|
|
'data',
|
|
'remoting',
|
|
'web',
|
|
'ldap',
|
|
'acl',
|
|
'config',
|
|
'cas',
|
|
'openid',
|
|
'taglibs',
|
|
'aspects',
|
|
'crypto',
|
|
'messaging',
|
|
'test'
|
|
]
|
|
|
|
include modules
|
|
|
|
modules.each {name ->
|
|
def p = findProject(":${name}")
|
|
p.name = "spring-security-${name}"
|
|
p.buildFileName = "${name}.gradle"
|
|
}
|
|
|
|
def String[] itest = [
|
|
'web',
|
|
'context'
|
|
]
|
|
|
|
include itest
|
|
|
|
itest.each { name ->
|
|
def p = findProject(":${name}")
|
|
p.name = "itest-${name}"
|
|
p.buildFileName = "itest-${name}.gradle"
|
|
p.projectDir = new File(settingsDir, "itest/${name}");
|
|
}
|
|
|
|
include 'docs', 'docs:manual', 'docs:guides'
|
|
|
|
def docs = findProject(':docs')
|
|
docs.buildFileName = 'docs.gradle'
|
|
|
|
include 'bom'
|
|
|
|
findProject(':bom').name = 'spring-security-bom'
|
|
|
|
includeSamples("samples/xml")
|
|
includeSamples("samples/javaconfig")
|
|
|
|
void includeSamples(String samplesDir) {
|
|
FileTree tree = fileTree(samplesDir) {
|
|
include '**/*.gradle'
|
|
}
|
|
tree.each {File file ->
|
|
String projectDir = file.path.substring(file.path.indexOf(samplesDir), file.path.lastIndexOf('/'))
|
|
String projectPath = projectDir.substring(projectDir.lastIndexOf('/') + 1)
|
|
String projectNamePrefix = samplesDir.substring(samplesDir.lastIndexOf('/') + 1).toLowerCase();
|
|
|
|
include projectPath
|
|
|
|
def project = findProject(":${projectPath}")
|
|
|
|
project.name = "spring-security-samples-${projectNamePrefix}-${project.name}"
|
|
project.projectDir = new File(settingsDir, projectDir)
|
|
|
|
if (!project.buildFile.exists()) {
|
|
project.buildFileName = file.path.substring(file.path.lastIndexOf('/') + 1)
|
|
}
|
|
}
|
|
}
|