Skip to content

Commit 4cae556

Browse files
committed
Add source links in javadoc
1 parent 9b8fd33 commit 4cae556

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

build.gradle.kts

+7
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import java.net.URL
12
import org.jetbrains.dokka.DokkaConfiguration.Visibility.PUBLIC
23
import org.jetbrains.dokka.gradle.DokkaTask
34

@@ -11,6 +12,7 @@ plugins {
1112

1213
group = "com.github.gabrielfeo"
1314
version = "0.10.0"
15+
val repoUrl = "https://github.com/gabrielfeo/gradle-enterprise-api-kotlin"
1416

1517
val downloadApiSpec by tasks.registering {
1618
val geVersion = providers.gradleProperty("gradle.enterprise.version").get()
@@ -75,6 +77,11 @@ java {
7577

7678
tasks.withType<DokkaTask>().configureEach {
7779
dokkaSourceSets.all {
80+
sourceLink {
81+
localDirectory.set(file("src/main/kotlin"))
82+
remoteUrl.set(URL("$repoUrl/blob/$version/src/main/kotlin"))
83+
remoteLineSuffix.set("#L")
84+
}
7885
jdkVersion.set(8)
7986
suppressGeneratedFiles.set(false)
8087
documentedVisibilities.set(setOf(PUBLIC))

0 commit comments

Comments
 (0)