Skip to content

Commit 7f0062e

Browse files
committed
update docs
Signed-off-by: Adam Ratzman <[email protected]>
1 parent 4525c4a commit 7f0062e

File tree

3 files changed

+28
-27
lines changed

3 files changed

+28
-27
lines changed

build.gradle.kts

Lines changed: 24 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,10 @@ buildscript {
3030
}
3131
}
3232

33+
dependencies {
34+
dokkaHtmlPlugin("org.jetbrains.dokka:kotlin-as-java-plugin:1.4.20")
35+
}
36+
3337
group = "com.adamratzman"
3438
version = "3.2.15"
3539

@@ -51,6 +55,7 @@ android {
5155
defaultConfig {
5256
minSdkVersion(15)
5357
targetSdkVersion(30)
58+
compileSdkVersion(30)
5459
versionCode = 1
5560
versionName = "1.0"
5661
testInstrumentationRunner = "android.support.test.runner.AndroidJUnitRunner"
@@ -83,7 +88,7 @@ val dokkaJar by tasks.registering(Jar::class) {
8388
group = JavaBasePlugin.DOCUMENTATION_GROUP
8489
description = "Docs"
8590
classifier = "javadoc"
86-
from(tasks.dokka)
91+
from(tasks.dokkaHtml)
8792
}
8893

8994
kotlin {
@@ -209,7 +214,7 @@ kotlin {
209214
implementation(kotlin("test"))
210215
implementation(kotlin("test-junit"))
211216
implementation("org.junit.jupiter:junit-jupiter:5.6.2")
212-
implementation("com.sparkjava:spark-core:2.9.1")
217+
implementation("com.sparkjava:spark-core:2.9.3")
213218
implementation("org.mockito:mockito-core:3.3.3")
214219
implementation("org.spekframework.spek2:spek-dsl-jvm:$spekVersion")
215220
runtimeOnly("org.spekframework.spek2:spek-runner-junit5:$spekVersion")
@@ -263,46 +268,39 @@ signing {
263268
}
264269

265270
tasks {
266-
val dokka by getting(DokkaTask::class) {
267-
outputFormat = "html"
268-
outputDirectory = "$buildDir/javadoc"
271+
val dokkaHtml by getting(DokkaTask::class) {
272+
outputDirectory.set(projectDir.resolve("docs"))
269273

270-
multiplatform {
274+
dokkaSourceSets {
271275
val js by creating {
272276
sourceLink {
273-
path = "/src"
274-
url = "https://github.com/adamint/spotify-web-api-kotlin/tree/master/"
275-
lineSuffix = "#L"
277+
localDirectory.set(file("src"))
278+
remoteUrl.set(uri("https://github.com/adamint/spotify-web-api-kotlin/tree/master/").toURL())
279+
remoteLineSuffix.set("#L")
276280
}
277281
}
278282
val jvm by creating {
279283
sourceLink {
280-
path = "/src"
281-
url = "https://github.com/adamint/spotify-web-api-kotlin/tree/master/"
282-
lineSuffix = "#L"
284+
localDirectory.set(file("src"))
285+
remoteUrl.set(uri("https://github.com/adamint/spotify-web-api-kotlin/tree/master/").toURL())
286+
remoteLineSuffix.set("#L")
287+
283288
}
284289
}
285290

286291
register("common") {
287292
sourceLink {
288-
path = "/src"
289-
url = "https://github.com/adamint/spotify-web-api-kotlin/tree/master/"
290-
lineSuffix = "#L"
293+
localDirectory.set(file("src"))
294+
remoteUrl.set(uri("https://github.com/adamint/spotify-web-api-kotlin/tree/master/").toURL())
295+
remoteLineSuffix.set("#L")
291296
}
292297
}
293298

294299
register("global") {
295300
sourceLink {
296-
path = "/src"
297-
url = "https://github.com/adamint/spotify-web-api-kotlin/tree/master/"
298-
lineSuffix = "#L"
299-
}
300-
301-
sourceRoot {
302-
path = kotlin.sourceSets.getByName("jvmMain").kotlin.srcDirs.first().toString()
303-
}
304-
sourceRoot {
305-
path = kotlin.sourceSets.getByName("commonMain").kotlin.srcDirs.first().toString()
301+
localDirectory.set(file("src"))
302+
remoteUrl.set(uri("https://github.com/adamint/spotify-web-api-kotlin/tree/master/").toURL())
303+
remoteLineSuffix.set("#L")
306304
}
307305
}
308306
}
@@ -327,7 +325,7 @@ tasks {
327325

328326
val publishJvm by registering(Task::class) {
329327
dependsOn.add(check)
330-
dependsOn.add(dokka)
328+
dependsOn.add(dokkaHtml)
331329
dependsOn.add("publishJvmPublicationToNexusRepository")
332330
}
333331

gradle.properties

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
systemProp.org.gradle.internal.publish.checksums.insecure=true
1+
systemProp.org.gradle.internal.publish.checksums.insecure=true
2+
org.gradle.daemon=true
3+
org.gradle.jvmargs=-Xmx4000m

settings.gradle.kts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ pluginManagement {
2222
repositories {
2323
mavenCentral()
2424
jcenter()
25+
gradlePluginPortal()
2526
google()
2627
maven { url = java.net.URI("https://plugins.gradle.org/m2/") }
2728
}

0 commit comments

Comments
 (0)