Skip to content

Commit

Permalink
Fix javadoc generation for the _extjars.
Browse files Browse the repository at this point in the history
  • Loading branch information
nedtwigg committed Mar 26, 2020
1 parent d14e227 commit 90b1f90
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ This document is intended for Spotless developers.
We adhere to the [keepachangelog](https://keepachangelog.com/en/1.0.0/) format (starting after version `1.27.0`).

## [Unreleased]
### Fixed
* Javadoc for the `ext/eclipse-*` projects.

## [1.28.0] - 2020-03-20
### Added
Expand Down
9 changes: 5 additions & 4 deletions gradle/java-publish.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ def makeLink = { url, text -> "<a href=\"${url}\" style=\"text-transform: none;\
def javadocInfo = '<h2>' + makeLink("https://github.com/${org}/${name}", "${group}:${project.ext.artifactId}:${version}") +
' by ' + makeLink('https://www.diffplug.com', 'DiffPlug') + '</h2>'

String dotdotGradle = project.name.startsWith('eclipse-') ? '../../gradle' : '../gradle'
apply plugin: 'org.jdrupes.mdoclet'
javadoc {
// Where it's possible to name parameters and methods clearly enough
Expand All @@ -33,12 +34,12 @@ javadoc {
options.header javadocInfo
options.footer javadocInfo
// setup links
options.linksOffline('https://docs.oracle.com/javase/8/docs/api/', '../gradle/javadoc/java8')
options.linksOffline('https://docs.gradle.org/2.14/javadoc/', '../gradle/javadoc/gradle')
options.linksOffline('https://docs.oracle.com/javase/8/docs/api/', "${dotdotGradle}/javadoc/java8")
options.linksOffline('https://docs.gradle.org/2.14/javadoc/', "${dotdotGradle}/javadoc/gradle")

// links to javadoc from the other versions
options.linksOffline("https://javadoc.io/static/com.diffplug.spotless/spotless-lib/${rootProject.spotlessChangelog.versionLast}", "../gradle/javadoc/spotless-lib")
options.linksOffline("https://javadoc.io/static/com.diffplug.spotless/spotless-lib-extra/${rootProject.spotlessChangelog.versionLast}", "../gradle/javadoc/spotless-lib-extra")
options.linksOffline("https://javadoc.io/static/com.diffplug.spotless/spotless-lib/${rootProject.spotlessChangelog.versionLast}", "${dotdotGradle}/javadoc/spotless-lib")
options.linksOffline("https://javadoc.io/static/com.diffplug.spotless/spotless-lib-extra/${rootProject.spotlessChangelog.versionLast}", "${dotdotGradle}/javadoc/spotless-lib-extra")
}

task javadocJar(type: Jar, dependsOn: javadoc) {
Expand Down

0 comments on commit 90b1f90

Please sign in to comment.