2020-01-10 21:48:43 +08:00
|
|
|
plugins {
|
2020-01-23 03:24:37 +08:00
|
|
|
id "org.asciidoctor.jvm.convert"
|
|
|
|
id "org.asciidoctor.jvm.pdf"
|
|
|
|
id "org.springframework.boot.conventions"
|
|
|
|
id "org.springframework.boot.internal-dependency-management"
|
|
|
|
id "org.springframework.boot.maven-plugin"
|
|
|
|
id "org.springframework.boot.optional-dependencies"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
description = "Spring Boot Maven Plugin"
|
|
|
|
|
|
|
|
configurations {
|
|
|
|
documentation
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2020-01-23 03:24:37 +08:00
|
|
|
api platform(project(":spring-boot-project:spring-boot-parent"))
|
|
|
|
api project(":spring-boot-project:spring-boot-tools:spring-boot-buildpack-platform")
|
2020-01-15 20:32:37 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
compileOnly "org.apache.maven.plugin-tools:maven-plugin-annotations"
|
|
|
|
compileOnly "org.sonatype.plexus:plexus-build-api"
|
2020-01-10 21:48:43 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
implementation project(":spring-boot-project:spring-boot-tools:spring-boot-loader-tools")
|
|
|
|
implementation "org.apache.maven.shared:maven-common-artifact-filters"
|
|
|
|
implementation "org.apache.maven:maven-plugin-api"
|
2020-01-10 21:48:43 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
intTestImplementation platform(project(":spring-boot-project:spring-boot-parent"))
|
|
|
|
intTestImplementation "org.apache.maven.shared:maven-invoker"
|
|
|
|
intTestImplementation "org.assertj:assertj-core"
|
|
|
|
intTestImplementation "org.junit.jupiter:junit-jupiter"
|
2020-01-10 21:48:43 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
optional platform(project(":spring-boot-project:spring-boot-parent"))
|
|
|
|
optional "org.apache.maven.plugins:maven-shade-plugin"
|
2020-01-10 21:48:43 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
runtimeOnly "org.sonatype.plexus:plexus-build-api"
|
2020-01-10 21:48:43 +08:00
|
|
|
|
2020-01-23 03:24:37 +08:00
|
|
|
testImplementation "org.assertj:assertj-core"
|
|
|
|
testImplementation "org.junit.jupiter:junit-jupiter"
|
|
|
|
testImplementation "org.mockito:mockito-core"
|
|
|
|
testImplementation "org.springframework:spring-core"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
syncDocumentationSourceForAsciidoctor {
|
|
|
|
from(documentPluginGoals) {
|
2020-01-23 03:24:37 +08:00
|
|
|
into "asciidoc/goals"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
asciidoctor {
|
|
|
|
sources {
|
2020-01-23 03:24:37 +08:00
|
|
|
include "index.adoc"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
syncDocumentationSourceForAsciidoctorPdf {
|
|
|
|
from(documentPluginGoals) {
|
2020-01-23 03:24:37 +08:00
|
|
|
into "asciidoc/goals"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
asciidoctorPdf {
|
|
|
|
sources {
|
2020-01-23 03:24:37 +08:00
|
|
|
include "index.adoc"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
tasks.withType(org.asciidoctor.gradle.jvm.AbstractAsciidoctorTask) {
|
2020-01-23 03:24:37 +08:00
|
|
|
attributes "maven-jar-plugin-version": "1.2.3",
|
|
|
|
"maven-failsafe-plugin-version": "1.2.3",
|
|
|
|
"build-helper-maven-plugin-version": "1.2.3"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
task zip(type: Zip) {
|
|
|
|
dependsOn asciidoctor, asciidoctorPdf
|
2020-01-23 03:24:37 +08:00
|
|
|
duplicatesStrategy "fail"
|
2020-01-10 21:48:43 +08:00
|
|
|
from(asciidoctorPdf.outputDir) {
|
2020-01-23 03:24:37 +08:00
|
|
|
into "pdf"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
from(asciidoctor.outputDir) {
|
2020-01-23 03:24:37 +08:00
|
|
|
into "html"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
prepareMavenBinaries {
|
2020-01-23 03:24:37 +08:00
|
|
|
versions "3.6.2", "3.5.4"
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
artifacts {
|
2020-01-23 03:24:37 +08:00
|
|
|
"documentation" zip
|
2020-01-10 21:48:43 +08:00
|
|
|
}
|