Add bom finder to download widget

This commit is contained in:
Dave Syer
2015-07-10 15:23:49 +01:00
parent a11f553a72
commit 3b2484f631
4 changed files with 16 additions and 2 deletions

View File

@@ -8,7 +8,7 @@ apply plugin: "io.spring.dependency-management"
dependencyManagement {
imports {
mavenBom '{@= groupId @}:spring-cloud-config:{@= version @}'
mavenBom '{@= groupId @}:spring-cloud-config:{@= findBom(version) @}'
}
}

13
_includes/custom.js Normal file
View File

@@ -0,0 +1,13 @@
var defaultBomVersion = "Angel.SR3";
var boms = {
"1.0.0.RELEASE": "Angel.RELEASE",
"1.0.1.RELEASE": "Angel.SR1",
"1.0.2.RELEASE": "Angel.SR3",
"1.0.3.BUILD-SNAPSHOT": "Angel.BUILD-SNAPSHOT",
"1.1.0.BUILD-SNAPSHOT": "Brixton.BUILD-SNAPSHOT"
};
function findBom(version) {
if (boms[version]) return boms[version];
return defaultBomVersion;
}

View File

@@ -3,7 +3,7 @@
<dependency>
<groupId>{@= groupId @}</groupId>
<artifactId>spring-cloud-config</artifactId>
<version>{@= version @}</version>
<version>{@= findBom(version) @}</version>
<type>pom</type>
<scope>import</scope>
</dependency>

View File

@@ -48,6 +48,7 @@ Config Client features (for Spring applications):
<span id="quick-start"></span>
## Quick Start
<script type="text/javascript">{% include custom.js %}</script>
{% include download_widget.md %}
As long as Spring Boot Actuator and Spring Config Client are on the