Skip to content

Commit 141c65c

Browse files
committed
HHH-19827 Add task dependencies and PDF code theme
1 parent dc11197 commit 141c65c

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

documentation/documentation.gradle

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,8 @@ asciidoctorj {
253253
'html.meta.project-key': 'orm',
254254
'html.outdated-content.project-key': 'orm',
255255
'html-meta-description': 'Hibernate ORM, relational persistence for idiomatic Java',
256-
'html-meta-keywords': 'hibernate, orm, hibernate orm, database, db, jpa, sql'
256+
'html-meta-keywords': 'hibernate, orm, hibernate orm, database, db, jpa, sql',
257+
'html-meta-version-family': ormBuildDetails.hibernateVersion.family
257258

258259
options logDocuments: true
259260
}
@@ -889,9 +890,20 @@ tasks.withType(AsciidoctorTask).configureEach {
889890
}
890891
// See https://docs.asciidoctor.org/gradle-plugin/latest/common-task-configuration/#choosing-an-execution-mode-for-asciidoctorj
891892
executionMode = ExecutionMode.JAVA_EXEC
893+
894+
dependsOn 'unpackTheme'
892895
}
893896

894897
tasks.withType(AsciidoctorPdfTask).configureEach {
895898
// See https://docs.asciidoctor.org/gradle-plugin/latest/common-task-configuration/#choosing-an-execution-mode-for-asciidoctorj
896899
executionMode = ExecutionMode.JAVA_EXEC
900+
901+
asciidoctorj {
902+
requires rootProject.layout.buildDirectory.dir("unpacked-theme").get()
903+
.dir("hibernate-asciidoctor-theme").dir("asciidoc").dir("theme").file("hibernate.rb").asFile.absolutePath
904+
}
905+
906+
attributes 'rouge-style': 'hibernate'
907+
908+
dependsOn 'unpackTheme'
897909
}

0 commit comments

Comments
 (0)