File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,9 @@ def documentedSubprojects = ["kotlinx-serialization-core",
1212 " kotlinx-serialization-properties" ,
1313 " kotlinx-serialization-hocon" ,
1414 " kotlinx-serialization-protobuf" ]
15+
16+ def jvmOnlySubprojects = [" kotlinx-serialization-hocon" ]
17+
1518subprojects {
1619 if (! (name in documentedSubprojects)) return
1720 apply plugin : ' org.jetbrains.dokka'
@@ -72,6 +75,16 @@ subprojects {
7275 matchingRegex. set(" org\\ .intellij\\ .lang\\ .annotations(\$ |\\ .).*" )
7376 suppress. set(true )
7477 }
78+
79+ sourceLink {
80+ // sources directory for MPP configured in gradle/configure-source-sets.gradle:61
81+ // in short - kotlin.srcDirs = ["$sourceSet.name/src"]
82+ def sourcesPath = project. name in jvmOnlySubprojects ? " src/main/kotlin" : " $name /src"
83+ def relProjectPath = rootProject. projectDir. toPath(). relativize(projectDir. toPath())
84+ localDirectory. set(file(sourcesPath))
85+ remoteUrl. set(new URL (" https://github.com/Kotlin/kotlinx.serialization/tree/master/$relProjectPath /$sourcesPath " ))
86+ remoteLineSuffix. set(" #L" )
87+ }
7588 }
7689 }
7790 }
You can’t perform that action at this time.
0 commit comments