From ac979303a767d53bcf38ae35c5a943111340c097 Mon Sep 17 00:00:00 2001 From: Simon Binder Date: Mon, 21 Jul 2025 17:27:07 +0200 Subject: [PATCH] Dokka: Link to source --- README.md | 13 +++++++++++-- .../src/main/kotlin/dokka-convention.gradle.kts | 15 +++++++++++++++ 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d589bd74..cd8e7cba 100644 --- a/README.md +++ b/README.md @@ -6,9 +6,18 @@ # PowerSync Kotlin Multiplatform SDK -This is the PowerSync client SDK for Kotlin Mutliplatform. This SDK currently supports Android and iOS as targets. +This is the PowerSync client SDK for Kotlin. This SDK currently supports the following Kotlin targets: -See a summary of features [here](https://docs.powersync.com/client-sdk-references/kotlin-multiplatform#sdk-features). +- Android +- JVM +- iOS +- macOS +- watchOS + +If you need support for additional targets, please reach out! + +See a summary of features [here](https://docs.powersync.com/client-sdk-references/kotlin-multiplatform#sdk-features) +and API documentation [here](https://powersync-ja.github.io/powersync-kotlin/). ## Structure: Packages diff --git a/plugins/build-plugin/src/main/kotlin/dokka-convention.gradle.kts b/plugins/build-plugin/src/main/kotlin/dokka-convention.gradle.kts index 2bdc662f..5de507b8 100644 --- a/plugins/build-plugin/src/main/kotlin/dokka-convention.gradle.kts +++ b/plugins/build-plugin/src/main/kotlin/dokka-convention.gradle.kts @@ -4,6 +4,11 @@ plugins { // Shared Dokka config for additional assets dokka { + val commit = providers.exec { + executable = "git" + args("rev-parse", "HEAD") + }.standardOutput.asText + pluginsConfiguration.html { val docsAssetsDir = rootProject.file("docs/assets") @@ -18,4 +23,14 @@ dokka { customStyleSheets.from(docsAssetsDir.resolve("doc-styles.css")) templatesDir = file(docsAssetsDir.resolve("dokka-templates")) } + + dokkaSourceSets.configureEach { + sourceLink { + localDirectory.set(project.rootDir) + remoteUrl.set(commit.map { commit -> + uri("https://github.com/powersync-ja/powersync-kotlin/tree/${commit.trim()}/") + }) + remoteLineSuffix.set("#L") + } + } }