From 196fa8f2f0f8179c0bd6fe86b68b6c203c0da3ca Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Thu, 5 Jun 2014 08:20:47 +0100 Subject: [PATCH] Add additional gradle hints for eclipse Fixes gh-16 --- templates/starter-build.gradle | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/templates/starter-build.gradle b/templates/starter-build.gradle index 678aab59..fcc3cd04 100644 --- a/templates/starter-build.gradle +++ b/templates/starter-build.gradle @@ -13,8 +13,9 @@ buildscript { } } -apply plugin: '${language}' -apply plugin: 'eclipse' +apply plugin: '${language}'<% if (packaging=='war') { %> +apply plugin: 'eclipse-wtp'<% } else { %> +apply plugin: 'eclipse'<% } %> apply plugin: 'idea' apply plugin: 'spring-boot' <% if (packaging=='war') { %> apply plugin: 'war' @@ -45,6 +46,13 @@ dependencies {<% styles.each { %> testCompile("org.springframework.boot:spring-boot-starter-test") } +eclipse { + classpath { + containers.remove(''org.eclipse.jdt.launching.JRE_CONTAINER') + containers 'org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-${javaVersion}' + } +} + task wrapper(type: Wrapper) { gradleVersion = '1.12' }