-
Notifications
You must be signed in to change notification settings - Fork 59
/
Copy pathbuild.gradle.kts
90 lines (74 loc) · 2.74 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
import space.kscience.gradle.useApache2Licence
import space.kscience.gradle.useSPCTeam
plugins {
alias(spclibs.plugins.kscience.project)
alias(spclibs.plugins.kotlinx.kover)
}
allprojects {
repositories {
maven("https://repo.kotlin.link")
maven("https://oss.sonatype.org/content/repositories/snapshots")
mavenCentral()
}
group = "space.kscience"
version = "0.4.3-dev-1"
}
dependencies {
subprojects.forEach {
dokka(it)
}
}
dokka{
dokkaSourceSets.configureEach {
val readmeFile = projectDir.resolve("README.md")
if (readmeFile.exists()) includes.from(readmeFile)
}
}
subprojects {
if (name.startsWith("kmath")) apply<MavenPublishPlugin>()
plugins.withId("org.jetbrains.dokka") {
dokka {
dokkaSourceSets.configureEach {
val readmeFile = projectDir.resolve("README.md")
if (readmeFile.exists()) includes.from(readmeFile)
val kotlinDirPath = "src/$name/kotlin"
val kotlinDir = file(kotlinDirPath)
if (kotlinDir.exists()) sourceLink {
localDirectory.set(kotlinDir)
remoteUrl(
"https://github.com/SciProgCentre/kmath/tree/master/${name}/$kotlinDirPath"
)
}
fun externalDocumentationLink(url: String, packageListUrl: String? = null){
externalDocumentationLinks.register(url) {
url(url)
packageListUrl?.let {
packageListUrl(it)
}
}
}
externalDocumentationLink("https://commons.apache.org/proper/commons-math/javadocs/api-3.6.1/")
externalDocumentationLink("https://deeplearning4j.org/api/latest/")
externalDocumentationLink("https://axelclk.bitbucket.io/symja/javadoc/")
externalDocumentationLink(
"https://kotlin.github.io/kotlinx.coroutines/kotlinx-coroutines-core/",
"https://kotlin.github.io/kotlinx.coroutines/package-list",
)
externalDocumentationLink(
"https://breandan.net/kotlingrad/kotlingrad",
"https://breandan.net/kotlingrad/package-list",
)
}
}
}
}
readme.readmeTemplate = file("docs/templates/README-TEMPLATE.md")
ksciencePublish {
pom("https://github.com/SciProgCentre/kmath") {
useApache2Licence()
useSPCTeam()
}
repository("spc", "https://maven.sciprog.center/kscience")
central()
}
apiValidation.nonPublicMarkers.add("space.kscience.kmath.UnstableKMathAPI")