2010-03-29 06:54:41 +08:00
|
|
|
apply plugin: 'base'
|
2010-01-20 12:14:48 +08:00
|
|
|
|
2009-12-05 05:33:17 +08:00
|
|
|
allprojects {
|
2011-02-11 04:18:40 +08:00
|
|
|
version = '3.1.0.CI-SNAPSHOT'
|
2010-01-18 10:02:28 +08:00
|
|
|
releaseBuild = version.endsWith('RELEASE')
|
2010-01-21 13:28:17 +08:00
|
|
|
snapshotBuild = version.endsWith('SNAPSHOT')
|
|
|
|
|
2010-01-13 08:44:05 +08:00
|
|
|
group = 'org.springframework.security'
|
|
|
|
|
2009-12-05 05:33:17 +08:00
|
|
|
repositories {
|
2011-01-11 01:27:22 +08:00
|
|
|
mavenLocal()
|
2009-12-05 05:33:17 +08:00
|
|
|
mavenCentral()
|
2010-03-03 23:40:57 +08:00
|
|
|
mavenRepo name: 'SpringSource Milestone Repo', urls: 'http://repository.springsource.com/maven/bundles/milestone'
|
|
|
|
mavenRepo name: 'SpringSource Maven Snapshot Repo', urls: 'http://maven.springframework.org/snapshot/'
|
|
|
|
mavenRepo name: 'SpringSource Enterprise Release', urls: 'http://repository.springsource.com/maven/bundles/release'
|
|
|
|
mavenRepo name: 'SpringSource Enterprise External', urls: 'http://repository.springsource.com/maven/bundles/external'
|
2009-12-05 05:33:17 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2010-08-05 04:35:57 +08:00
|
|
|
// Set up different subproject lists for individual configuration
|
2010-08-04 09:04:40 +08:00
|
|
|
javaProjects = subprojects.findAll { project -> project.name != 'docs' && project.name != 'faq' && project.name != 'manual' }
|
|
|
|
sampleProjects = subprojects.findAll { project -> project.name.startsWith('spring-security-samples') }
|
|
|
|
itestProjects = subprojects.findAll { project -> project.name.startsWith('itest') }
|
|
|
|
coreModuleProjects = javaProjects - sampleProjects - itestProjects
|
|
|
|
aspectjProjects = [project(':spring-security-aspects'), project(':spring-security-samples-aspectj')]
|
|
|
|
|
|
|
|
configure(javaProjects) {
|
|
|
|
apply from: "$rootDir/gradle/javaprojects.gradle"
|
|
|
|
}
|
|
|
|
|
|
|
|
configure(coreModuleProjects) {
|
|
|
|
// Gives better names in structure101 jar diagram
|
|
|
|
sourceSets.main.classesDir = new File(buildDir, "classes/" + project.name.substring("spring-security".length() + 1))
|
2011-02-16 23:57:22 +08:00
|
|
|
apply plugin: 'bundlor'
|
|
|
|
bundlor.expansions = bundlorProperties
|
|
|
|
apply from: "$rootDir/gradle/maven-deployment.gradle"
|
|
|
|
apply plugin: 'emma'
|
2010-08-04 09:04:40 +08:00
|
|
|
}
|
|
|
|
|
2010-08-25 01:27:44 +08:00
|
|
|
task coreBuild {
|
|
|
|
dependsOn coreModuleProjects*.tasks*.matching { task -> task.name == 'build' }
|
|
|
|
}
|
|
|
|
|
2010-08-04 09:04:40 +08:00
|
|
|
configure (aspectjProjects) {
|
2011-02-16 23:57:22 +08:00
|
|
|
apply plugin: 'aspectj'
|
2010-08-04 09:04:40 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
apply from: "$rootDir/gradle/dist.gradle"
|
|
|
|
|
2010-08-25 05:36:42 +08:00
|
|
|
apply plugin: 'idea'
|
|
|
|
|
2010-08-23 05:29:11 +08:00
|
|
|
configure(javaProjects) {
|
2010-08-03 10:01:53 +08:00
|
|
|
apply plugin: 'idea'
|
2010-08-18 21:11:06 +08:00
|
|
|
apply plugin: 'eclipse'
|
2010-08-21 21:15:54 +08:00
|
|
|
|
2010-07-07 06:52:11 +08:00
|
|
|
ideaModule {
|
2010-08-21 21:15:54 +08:00
|
|
|
downloadJavadoc=false
|
|
|
|
excludeDirs.add(buildDir)
|
2010-07-07 06:52:11 +08:00
|
|
|
gradleCacheVariable = 'GRADLE_CACHE'
|
2010-08-21 21:15:54 +08:00
|
|
|
outputDir = "$rootProject.projectDir/intellij/out" as File
|
|
|
|
testOutputDir = "$rootProject.projectDir/intellij/testOut" as File
|
2010-08-25 05:36:42 +08:00
|
|
|
whenConfigured { module ->
|
|
|
|
def allClasses = module.dependencies.findAll() { dep ->
|
|
|
|
if (dep instanceof org.gradle.plugins.idea.model.ModuleLibrary
|
|
|
|
&& dep.classes.find { path ->
|
|
|
|
path.url.matches('.*jcl-over-slf4j.*') ||
|
|
|
|
path.url.matches('.*servlet-api.*') ||
|
|
|
|
path.url.matches('.*jsp-api.*')
|
|
|
|
}) {
|
|
|
|
dep.scope = 'COMPILE'
|
|
|
|
dep.exported = false
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2010-07-07 06:52:11 +08:00
|
|
|
}
|
2011-03-07 02:46:56 +08:00
|
|
|
// GRADLE-1116
|
|
|
|
eclipseClasspath.whenConfigured { classpath ->
|
|
|
|
classpath.entries.removeAll { entry -> entry.path.endsWith('/build/classes/test') }
|
|
|
|
}
|
2010-07-08 05:40:17 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
ideaModule {
|
2010-08-21 21:15:54 +08:00
|
|
|
excludeDirs += file('.gradle')
|
|
|
|
excludeDirs += file('buildSrc/build')
|
|
|
|
excludeDirs += file('buildSrc/.gradle')
|
2010-07-08 05:40:17 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
ideaProject {
|
|
|
|
javaVersion = '1.6'
|
2010-08-25 05:36:42 +08:00
|
|
|
subprojects = [rootProject] + javaProjects
|
2010-08-03 10:01:53 +08:00
|
|
|
withXml { node ->
|
2010-08-21 21:15:54 +08:00
|
|
|
// Use git
|
|
|
|
def vcsConfig = node.component.find { it.'@name' == 'VcsDirectoryMappings' }
|
|
|
|
vcsConfig.mapping[0].'@vcs' = 'Git'
|
2010-08-03 10:01:53 +08:00
|
|
|
}
|
|
|
|
}
|
2010-08-05 04:35:57 +08:00
|
|
|
|
|
|
|
task wrapper(type: Wrapper) {
|
2011-03-07 02:31:33 +08:00
|
|
|
gradleVersion = '1.0-milestone-1'
|
2010-08-05 04:35:57 +08:00
|
|
|
}
|