Skip to content

Commit

Permalink
Add Dokka and KDoc publishing workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
BenWoodworth committed Nov 5, 2023
1 parent c10cee0 commit da6daa0
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 1 deletion.
30 changes: 29 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Publish
on:
push:
tags: [ 'v*' ]
branches: [ 'main' ]
branches: [ 'main', 'publishing' ]

env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
Expand Down Expand Up @@ -31,3 +31,31 @@ jobs:

- name: Publish to Maven
run: ./gradlew ciPublish

docs:
needs: publish

permissions:
pages: write
id-token: write

environment:
name: Publish KDoc
url: ${{ steps.deployment.outputs.page_url }}

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Set up JDK
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'

- name: Build KDoc
run: ./gradlew dokkaHtml

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import org.jetbrains.kotlin.gradle.plugin.KotlinTargetWithTests

plugins {
kotlin("multiplatform") version "1.9.20"
id("org.jetbrains.dokka") version "1.9.10"
id("org.jetbrains.kotlinx.binary-compatibility-validator") version "0.13.2"
id("parameterize.library-conventions")
}
Expand Down
3 changes: 3 additions & 0 deletions src/commonMain/kotlin/ParameterDelegate.kt
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ import kotlin.reflect.KProperty
* through the current iterator.
*/

/**
* @suppress bleh
*/
public class ParameterDelegate<@Suppress("unused") out T> internal constructor() {
/*
* The internal state does not use the generic type, so T is purely for
Expand Down
6 changes: 6 additions & 0 deletions src/commonMain/kotlin/Parameterize.kt
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,9 @@ internal class ParameterizeException(override val message: String) : Exception(m
public class ParameterizeScope internal constructor(
private val state: ParameterizeState,
) {
/**
* @suppress
*/
override fun toString(): String =
state.getFailureArguments().joinToString(
prefix = "ParameterizeScope(",
Expand Down Expand Up @@ -170,6 +173,9 @@ public class ParameterizeScope internal constructor(
state.getParameterArgument(this, property as KProperty<T>)


/**
* @suppress
*/
@JvmInline
public value class Parameter<out T> internal constructor(
internal val arguments: Iterable<T>
Expand Down

0 comments on commit da6daa0

Please sign in to comment.