Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add a 'bill of materials' project for Maven users

Add 'spring-framework-bom' meta-project that contains the other projects
in a dependencyManagement section.

Issue: SPR-11138
  • Loading branch information...
commit 92e144a8a8471b024d32459f23f4151023d2f9b1 1 parent 079fb2d
@philwebb philwebb authored
View
35 build.gradle
@@ -853,6 +853,41 @@ project("spring-aspects") {
}
}
+project("spring-framework-bom") {
+ description = "Spring Framework (Bill of Materials)"
+
+ configurations.archives.artifacts.clear()
+ artifacts {
+ // work around GRADLE-2406 by attaching text artifact
+ archives(file("spring-framework-bom.txt"))
+ }
+
+ install {
+ repositories.mavenInstaller {
+ pom.whenConfigured {
+ packaging = "pom"
+ withXml {
+ asNode().children().last() + {
+ delegate.dependencyManagement {
+ delegate.dependencies {
+ parent.subprojects.sort { "$it.name" }.each { p ->
+ if (p.hasProperty("merge") && p.merge.into == null && p != project) {
+ delegate.dependency {
+ delegate.groupId(p.group)
+ delegate.artifactId(p.name)
+ delegate.version(p.version)
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+}
+
configure(rootProject) {
description = "Spring Framework"
View
1  settings.gradle
@@ -23,6 +23,7 @@ include "spring-webmvc"
include "spring-webmvc-portlet"
include "spring-webmvc-tiles3"
include "spring-websocket"
+include "spring-framework-bom"
// Exposes gradle buildSrc for IDE support
include "buildSrc"
View
2  spring-framework-bom/spring-framework-bom.txt
@@ -0,0 +1,2 @@
+This meta-project is used to generate a bill-of-materials POM that contains the other
+projects in a dependencyManagement section.
Please sign in to comment.
Something went wrong with that request. Please try again.