test {
useJUnitPlatform()
outputs.dir snippetsDir
}
asciidoctor {
configurations "asciidoctorExtensions"
inputs.dir snippetsDir
dependsOn test
doLast {
copy{
from ("${asciidoctor.outputDir}/html5")
into "$buildDir/resources/main/public/docs")
include "**/*.html"
}
Here is the example i refered the above solution from-
https://github.com/spring-projects/spring-restdocs-samples/blob/main/restful-notes-spring-hateoas/build.gradle
I am getting below error when i try to load index HTML
Unresolved directive in index.adoc – include::child.adoc[]
I tried below solution –
THe below solution didn’t worked
asciidoctor { configurations 'asciidoctorExtensions' inputs.dir snippetsDir sources { include 'index.adoc' } dependsOn test }
New contributor
Test Email is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.