From e6dbce792512b00483b262a7722b8e03a24daaa1 Mon Sep 17 00:00:00 2001 From: Rob Winch Date: Tue, 3 Mar 2020 22:25:34 -0600 Subject: [PATCH] Customize Gradle Asciidoctor build task to properly identify doc source. Other Spring Build Conventions based projects assume includes are in _includes but SBDG has includes outside of _includes. This means we must change the sources to only be 'index.adoc'. Update docs build to configure every task of type AbstractAsciidoctorTask so that asciidoctorPdf picks up the custom attributes set and the updated sources. --- spring-geode-docs/spring-geode-docs.gradle | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/spring-geode-docs/spring-geode-docs.gradle b/spring-geode-docs/spring-geode-docs.gradle index b94f0299..6346ead2 100644 --- a/spring-geode-docs/spring-geode-docs.gradle +++ b/spring-geode-docs/spring-geode-docs.gradle @@ -1,4 +1,5 @@ import org.apache.tools.ant.filters.ReplaceTokens +import org.asciidoctor.gradle.jvm.AbstractAsciidoctorTask apply plugin: 'io.spring.convention.docs' apply plugin: 'io.spring.convention.spring-test' @@ -18,7 +19,11 @@ dependencies { def versions = dependencyManagement.managedVersions -asciidoctor { +tasks.withType(AbstractAsciidoctorTask).configureEach { + clearSources() + sources { + include "index.adoc" + } def githubBaseUrl = "https://github.com/spring-projects/spring-boot-data-geode" def githubTag = snapshotBuild ? 'master' : project.version