mirror of https://github.com/apache/lucene.git
Add initial support for rendering javadocs.
This commit is contained in:
parent
5e2396d9fe
commit
3beb1cfd1e
10
build.gradle
10
build.gradle
|
@ -1,3 +1,5 @@
|
|||
import java.time.ZonedDateTime
|
||||
import java.time.format.DateTimeFormatter
|
||||
|
||||
plugins {
|
||||
id "base"
|
||||
|
@ -10,6 +12,13 @@ allprojects {
|
|||
version = "9.0.0-SNAPSHOT"
|
||||
}
|
||||
|
||||
ext {
|
||||
def tstamp = ZonedDateTime.now()
|
||||
buildDate = DateTimeFormatter.ofPattern("yyyy-MM-dd").format(tstamp)
|
||||
buildTime = DateTimeFormatter.ofPattern("HH:mm:ss").format(tstamp)
|
||||
buildYear = DateTimeFormatter.ofPattern("yyyy").format(tstamp)
|
||||
}
|
||||
|
||||
// Include smaller chunks configuring dedicated build areas.
|
||||
// Some of these intersect or add additional functionality.
|
||||
// The order of inclusion of these files shouldn't matter (but may
|
||||
|
@ -22,6 +31,7 @@ apply from: file('gradle/generate-defaults.gradle')
|
|||
// (java, tests)
|
||||
apply from: file('gradle/defaults.gradle')
|
||||
apply from: file('gradle/defaults-java.gradle')
|
||||
apply from: file('gradle/defaults-javadoc.gradle')
|
||||
apply from: file('gradle/testing/defaults-tests.gradle')
|
||||
apply from: file('gradle/testing/randomization.gradle')
|
||||
apply from: file('gradle/testing/fail-on-no-tests.gradle')
|
||||
|
|
|
@ -0,0 +1,38 @@
|
|||
// Configure javadoc defaults.
|
||||
|
||||
allprojects {
|
||||
plugins.withType(JavaPlugin) {
|
||||
tasks.matching { it.name == "javadoc" }.all {
|
||||
StandardJavadocDocletOptions opts = (options as StandardJavadocDocletOptions)
|
||||
opts.locale("en_US")
|
||||
opts.charSet = "UTF-8"
|
||||
opts.encoding = "UTF-8"
|
||||
opts.docEncoding = "UTF-8"
|
||||
|
||||
opts.noIndex()
|
||||
opts.memberLevel = JavadocMemberLevel.PROTECTED
|
||||
opts.version = true
|
||||
opts.author = true
|
||||
opts.use = true
|
||||
|
||||
opts.linksOffline(
|
||||
"https://docs.oracle.com/en/java/javase/11/docs/api/",
|
||||
project(":lucene").file("tools/javadoc/java11/").toString())
|
||||
|
||||
opts.tags(
|
||||
"lucene.experimental:a:WARNING: This API is experimental and might change in incompatible ways in the next release.",
|
||||
"lucene.internal:a:NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.",
|
||||
"lucene.spi:t:SPI Name (Note: This is case-insensitive. e.g., if the name is 'htmlStrip', 'htmlstrip' can be used when looking up the service).",
|
||||
)
|
||||
|
||||
opts.addStringOption("-release", "11")
|
||||
opts.addBooleanOption('Xdoclint:all,-accessibility,-missing,-html,-syntax', true)
|
||||
|
||||
def libName = project.path.startsWith(":lucene") ? "Lucene" : "Solr"
|
||||
opts.overview = file("src/main/java/overview.html").toString()
|
||||
opts.docTitle = "${libName} ${project.version} ${project.name} API"
|
||||
opts.windowTitle = "${libName} ${project.version} ${project.name} API"
|
||||
opts.bottom = "<i>Copyright © 2000-${buildYear} Apache Software Foundation. All Rights Reserved.</i>"
|
||||
}
|
||||
}
|
||||
}
|
|
@ -119,11 +119,6 @@ ext {
|
|||
|
||||
bareBonesDir = file("${buildDir}/bare-bones-html")
|
||||
|
||||
def tstamp = ZonedDateTime.now()
|
||||
buildDate = DateTimeFormatter.ofPattern("yyyy-MM-dd").format(tstamp)
|
||||
buildTime = DateTimeFormatter.ofPattern("HH:mm:ss").format(tstamp)
|
||||
buildYear = DateTimeFormatter.ofPattern("yyyy").format(tstamp)
|
||||
|
||||
// Some additional version properties are lazily computed
|
||||
// in setupLazyProps (because they need to be computed after evaluation is complete).
|
||||
props = [
|
||||
|
|
Loading…
Reference in New Issue