Provide support for resolving versions from Maven boms

This commit introduces a new module, initializer-version-resolver,
that provides support for resolving versions from the dependency
management of a Maven bom. Providing with the bom's coordinates
(groupId, artifactId, and version) a map of groupId:artifactId to
version, derived from the bom's <dependencyManagement>, is returned.

Closes gh-934
This commit is contained in:
Andy Wilkinson
2019-06-21 15:51:43 +01:00
parent 1c7a73c29f
commit ab8b1158fa
6 changed files with 327 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>io.spring.initializr</groupId>
<artifactId>initializr</artifactId>
<version>${revision}</version>
</parent>
<artifactId>initializr-version-resolver</artifactId>
<name>Spring Initializr :: Version Resolver</name>
<properties>
<main.basedir>${basedir}/..</main.basedir>
</properties>
<dependencies>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-resolver-provider</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven.resolver</groupId>
<artifactId>maven-resolver-connector-basic</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven.resolver</groupId>
<artifactId>maven-resolver-transport-http</artifactId>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>