Merge branch '2.7.x' into 3.0.x
Closes gh-34460
This commit is contained in:
@@ -0,0 +1,4 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
gradle.taskGraph.whenReady {
|
||||
println "developmentOnly exists = ${configurations.findByName('developmentOnly') != null}"
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
@@ -3,15 +3,18 @@ plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
options.compilerArgs = ['-Xlint:all']
|
||||
}
|
||||
|
||||
|
||||
task('javaCompileTasksCompilerArgs') {
|
||||
doFirst {
|
||||
tasks.withType(JavaCompile) {
|
||||
println "${name} compiler args: ${options.compilerArgs}"
|
||||
gradle.taskGraph.whenReady {
|
||||
gradle.taskGraph.allTasks.each {
|
||||
if (it instanceof JavaCompile) {
|
||||
println "${it.name} compiler args: ${it.options.compilerArgs}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,14 +3,18 @@ plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
tasks.withType(JavaCompile) {
|
||||
options.compilerArgs << '-Xlint:all'
|
||||
}
|
||||
|
||||
task('javaCompileTasksCompilerArgs') {
|
||||
doFirst {
|
||||
tasks.withType(JavaCompile) {
|
||||
println "${name} compiler args: ${options.compilerArgs}"
|
||||
gradle.taskGraph.whenReady {
|
||||
gradle.taskGraph.allTasks.each {
|
||||
if (it instanceof JavaCompile) {
|
||||
println "${it.name} compiler args: ${it.options.compilerArgs}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,10 +3,14 @@ plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
task('javaCompileTasksCompilerArgs') {
|
||||
doFirst {
|
||||
tasks.withType(JavaCompile) {
|
||||
println "${name} compiler args: ${options.compilerArgs}"
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
gradle.taskGraph.whenReady {
|
||||
gradle.taskGraph.allTasks.each {
|
||||
if (it instanceof JavaCompile) {
|
||||
println "${it.name} compiler args: ${it.options.compilerArgs}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
gradle.taskGraph.whenReady {
|
||||
gradle.taskGraph.allTasks.each {
|
||||
if (it instanceof JavaCompile) {
|
||||
println "${it.name} = ${it.options.encoding}"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
gradle.taskGraph.whenReady {
|
||||
def attributes = configurations.findByName('productionRuntimeClasspath').attributes
|
||||
println "${attributes.keySet().size()} productionRuntimeClasspath attributes:"
|
||||
attributes.keySet().each { attribute ->
|
||||
println " ${attribute}: ${attributes.getAttribute(attribute)}"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
id 'java'
|
||||
}
|
||||
|
||||
springBoot {
|
||||
mainClass = "com.example.Main"
|
||||
}
|
||||
|
||||
gradle.taskGraph.whenReady {
|
||||
analyzeConfiguration('productionRuntimeClasspath')
|
||||
analyzeConfiguration('runtimeClasspath')
|
||||
}
|
||||
|
||||
def analyzeConfiguration(String configurationName) {
|
||||
Configuration configuration = configurations.findByName(configurationName)
|
||||
println "$configurationName canBeResolved: ${configuration.canBeResolved}"
|
||||
println "$configurationName canBeConsumed: ${configuration.canBeConsumed}"
|
||||
}
|
||||
@@ -1,49 +0,0 @@
|
||||
plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
if (project.hasProperty('applyJavaPlugin')) {
|
||||
apply plugin: 'java'
|
||||
}
|
||||
|
||||
task('taskExists') {
|
||||
doFirst {
|
||||
println "${taskName} exists = ${tasks.findByName(taskName) != null}"
|
||||
}
|
||||
}
|
||||
|
||||
task('javaCompileEncoding') {
|
||||
doFirst {
|
||||
tasks.withType(JavaCompile) {
|
||||
println "${name} = ${options.encoding}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
task('configurationExists') {
|
||||
doFirst {
|
||||
println "${configurationName} exists = ${configurations.findByName(configurationName) != null}"
|
||||
}
|
||||
}
|
||||
|
||||
task('configurationAttributes') {
|
||||
doFirst {
|
||||
def attributes = configurations.findByName(configurationName).attributes
|
||||
println "${attributes.keySet().size()} ${configurationName} attributes:"
|
||||
attributes.keySet().each { attribute ->
|
||||
println " ${attribute}: ${attributes.getAttribute(attribute)}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
task('configurationResolvabilityAndConsumability') {
|
||||
if (project.hasProperty("configurationName")) {
|
||||
Configuration configuration = configurations.findByName(configurationName)
|
||||
def canBeResolved = configuration.canBeResolved
|
||||
def canBeConsumed = configuration.canBeConsumed
|
||||
doFirst {
|
||||
println "canBeResolved: ${canBeResolved}"
|
||||
println "canBeConsumed: ${canBeConsumed}"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -9,5 +9,5 @@ targetCompatibility = '1.8'
|
||||
bootBuildImage {
|
||||
builder = "projects.registry.vmware.com/springboot/spring-boot-cnb-builder:0.0.1"
|
||||
pullPolicy = "IF_NOT_PRESENT"
|
||||
bindings = [ "${projectDir}/bindings/ca-certificates:/platform/bindings/certificates" ]
|
||||
bindings = [ "${projectDir}/bindings/ca-certificates:/platform/bindings/certificates" as String ]
|
||||
}
|
||||
|
||||
@@ -9,5 +9,5 @@ targetCompatibility = '1.8'
|
||||
bootBuildImage {
|
||||
builder = "projects.registry.vmware.com/springboot/spring-boot-cnb-builder:0.0.1"
|
||||
pullPolicy = "IF_NOT_PRESENT"
|
||||
buildpacks = [ "file://${projectDir}/buildpack/hello-world" ]
|
||||
buildpacks = [ "file://${projectDir}/buildpack/hello-world" as String ]
|
||||
}
|
||||
|
||||
@@ -9,5 +9,5 @@ targetCompatibility = '1.8'
|
||||
bootBuildImage {
|
||||
builder = "projects.registry.vmware.com/springboot/spring-boot-cnb-builder:0.0.1"
|
||||
pullPolicy = "IF_NOT_PRESENT"
|
||||
buildpacks = [ "file://${projectDir}/hello-world.tgz" ]
|
||||
buildpacks = [ "file://${projectDir}/hello-world.tgz" as String ]
|
||||
}
|
||||
|
||||
@@ -7,10 +7,8 @@ bootJar {
|
||||
mainClass = 'com.example.Application'
|
||||
}
|
||||
|
||||
task resolveResolvableCopyOfUnresolvableConfiguration {
|
||||
doFirst {
|
||||
def copy = configurations.implementation.copyRecursive()
|
||||
copy.canBeResolved = true
|
||||
copy.resolve()
|
||||
}
|
||||
gradle.taskGraph.whenReady {
|
||||
def copy = configurations.implementation.copyRecursive()
|
||||
copy.canBeResolved = true
|
||||
copy.resolve()
|
||||
}
|
||||
|
||||
@@ -3,4 +3,6 @@ plugins {
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
applicationDefaultJvmArgs = ['-Dcom.foo=bar', '-Dcom.bar=baz']
|
||||
application {
|
||||
applicationDefaultJvmArgs = ['-Dcom.foo=bar', '-Dcom.bar=baz']
|
||||
}
|
||||
|
||||
@@ -2,9 +2,3 @@ plugins {
|
||||
id 'application'
|
||||
id 'org.springframework.boot' version '{version}'
|
||||
}
|
||||
|
||||
bootRun {
|
||||
doFirst {
|
||||
println "Main class name = ${bootRun.mainClass.get()}"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user