From acccd48d076799120dace12a7ed29e6414d70ab8 Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Wed, 20 Apr 2016 09:46:14 +0100 Subject: [PATCH] Align snippets with start.spring.io Uses a Boot parent and a Cloud BOM instead of the CLoud parent --- _includes/build.gradle | 16 ++++++++++++---- _includes/pom.xml | 16 ++++++++++++++-- index.html | 13 ++++++------- js/projectDocumentationWidget.js | 2 ++ 4 files changed, 34 insertions(+), 13 deletions(-) diff --git a/_includes/build.gradle b/_includes/build.gradle index 2b265fc..c13ae7b 100644 --- a/_includes/build.gradle +++ b/_includes/build.gradle @@ -1,10 +1,17 @@ buildscript { - dependencies { - classpath "io.spring.gradle:dependency-management-plugin:0.4.0.RELEASE" - } + ext { + springBootVersion = '{@= bootVersion @}' + } + repositories { + mavenCentral() + } + dependencies { + classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}") + } } -apply plugin: "io.spring.dependency-management" +apply plugin: 'java' +apply plugin: 'spring-boot' dependencyManagement { imports { @@ -16,3 +23,4 @@ dependencies { compile '{@= groupId @}:spring-cloud-starter-config' compile '{@= groupId @}:spring-cloud-starter-eureka' } + diff --git a/_includes/pom.xml b/_includes/pom.xml index 0224a45..1c5616c 100644 --- a/_includes/pom.xml +++ b/_includes/pom.xml @@ -1,8 +1,20 @@ - {@= groupId @} + org.springframework.boot spring-cloud-starter-parent - {@= version @} + {@= bootVersion @} + + + + {@= groupId @} + org.springframework.cloud + spring-cloud-dependencies + {@= version @} + pom + import + + + {@= groupId @} diff --git a/index.html b/index.html index f2efb2c..e879893 100644 --- a/index.html +++ b/index.html @@ -47,13 +47,12 @@ configure or extend to create a custom solution. ## Quick Start -The release train label (see below) is actually only used -explicitly in one artifact: "spring-cloud-starter-parent" (all the -others have normal "Spring" release labels tied to their parent -project). The starter parent is the one you can use as a BOM for -dependency management or as a parent POM (Maven only). Example using -the latest version with the config client and eureka (change the -artifact ids to pull in other starters): +The release train label (see below) is actually only used explicitly +in one artifact: "spring-cloud-dependencies" (all the others have +normal numeric release labels tied to their parent project). The +depednencies POM is the one you can use as a BOM for dependency +management. Example using the latest version with the config client +and eureka (change the artifact ids to pull in other starters): {% include download_widget.md %} diff --git a/js/projectDocumentationWidget.js b/js/projectDocumentationWidget.js index f6123f7..7f5a0eb 100644 --- a/js/projectDocumentationWidget.js +++ b/js/projectDocumentationWidget.js @@ -151,6 +151,8 @@ Spring.SnippetView = Backbone.View.extend({ render: function () { + this.model.bootVersion = this.model.version.indexOf("Brixton")!=-1 ? "1.3.3.RELEASE" : "1.2.8.RELEASE"; + console.log(JSON.stringify(this.model)) var html = $(this.combinedTemplate(this.model)); this.$el.html(html); if (ZeroClipboard.detectFlashSupport()) {