forked from spring-projects/spring-boot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
138 lines (118 loc) · 3.71 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
plugins {
id "org.asciidoctor.jvm.convert"
id "org.springframework.boot.conventions"
id "org.springframework.boot.maven-plugin"
id "org.springframework.boot.optional-dependencies"
}
description = "Spring Boot Maven Plugin"
configurations {
dependenciesBom
documentation
}
repositories {
maven {
url "https://repo.spring.io/release"
mavenContent {
includeGroup "io.spring.asciidoctor"
includeGroup "io.spring.asciidoctor.backends"
}
}
}
dependencies {
compileOnly("org.apache.maven.plugin-tools:maven-plugin-annotations")
compileOnly("org.sonatype.plexus:plexus-build-api")
implementation(project(":spring-boot-project:spring-boot-tools:spring-boot-buildpack-platform"))
implementation(project(":spring-boot-project:spring-boot-tools:spring-boot-loader-tools"))
implementation("org.apache.maven.shared:maven-common-artifact-filters") {
exclude(group: "javax.enterprise", module: "cdi-api")
exclude(group: "javax.inject", module: "javax.inject")
}
implementation("org.apache.maven:maven-plugin-api") {
exclude(group: "javax.enterprise", module: "cdi-api")
exclude(group: "javax.inject", module: "javax.inject")
}
intTestImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-buildpack-platform"))
intTestImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-loader-tools"))
intTestImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
intTestImplementation("org.apache.maven.shared:maven-invoker") {
exclude(group: "javax.inject", module: "javax.inject")
}
intTestImplementation("org.assertj:assertj-core")
intTestImplementation("org.junit.jupiter:junit-jupiter")
intTestImplementation("org.testcontainers:testcontainers")
intTestImplementation("org.testcontainers:junit-jupiter")
mavenOptionalImplementation("org.apache.maven.plugins:maven-shade-plugin") {
exclude(group: "javax.enterprise", module: "cdi-api")
exclude(group: "javax.inject", module: "javax.inject")
}
runtimeOnly("org.sonatype.plexus:plexus-build-api")
testImplementation("org.assertj:assertj-core")
testImplementation("org.junit.jupiter:junit-jupiter")
testImplementation("org.mockito:mockito-core")
testImplementation("org.mockito:mockito-junit-jupiter")
testImplementation("org.springframework:spring-core")
versionProperties(project(path: ":spring-boot-project:spring-boot-dependencies", configuration: "effectiveBom"))
}
syncDocumentationSourceForAsciidoctor {
from(documentPluginGoals) {
into "asciidoc/goals"
}
}
sourceSets {
intTest {
output.dir("${buildDir}/generated-resources", builtBy: "extractVersionProperties")
}
}
tasks.withType(org.asciidoctor.gradle.jvm.AbstractAsciidoctorTask) {
doFirst {
def versionEl = version.split("\\.")
attributes "spring-boot-xsd-version": versionEl[0] + '.' + versionEl[1]
}
}
asciidoctor {
sources {
include "index.adoc"
}
}
task asciidoctorPdf(type: org.asciidoctor.gradle.jvm.AsciidoctorTask) {
sources {
include "index.adoc"
}
}
syncDocumentationSourceForAsciidoctorPdf {
from(documentPluginGoals) {
into "asciidoc/goals"
}
}
javadoc {
options {
author = true
docTitle = "Spring Boot Maven Plugin ${project.version} API"
encoding = "UTF-8"
memberLevel = "protected"
outputLevel = "quiet"
splitIndex = true
use = true
windowTitle = "Spring Boot Maven Plugin ${project.version} API"
}
}
task zip(type: Zip) {
dependsOn asciidoctor, asciidoctorPdf
duplicatesStrategy "fail"
from(asciidoctorPdf.outputDir) {
into "reference/pdf"
rename "index.pdf", "${project.name}-reference.pdf"
}
from(asciidoctor.outputDir) {
into "reference/htmlsingle"
}
from(javadoc) {
into "api"
}
}
prepareMavenBinaries {
versions "3.8.1", "3.6.3", "3.5.4"
}
artifacts {
"documentation" zip
}