Skip to content

Commit

Permalink
added: kmmbridge support
Browse files Browse the repository at this point in the history
  • Loading branch information
hanrw committed Feb 2, 2024
1 parent 73ba8d5 commit 0ad3947
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 3 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@ on: [push]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
Expand All @@ -30,3 +28,11 @@ jobs:
files: ${{ github.workspace }}/build/reports/kover/report.xml
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
call-kmmbridge-publish:
permissions:
contents: write
packages: write
uses: touchlab/KMMBridgeGithubWorkflow/.github/workflows/[email protected]
with:
jvmVersion: 17
versionBaseProperty: LIBRARY_VERSION
5 changes: 4 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,7 @@ org.gradle.jvmargs=-Xmx2048M -Dfile.encoding=UTF-8 -Dkotlin.daemon.jvm.options\=
kotlin.mpp.enableCInteropCommonization=true

#Development
development=true
development=true

LIBRARY_VERSION=0.1.0
GROUP=com.snacks.lemonsqueezy
4 changes: 4 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ kover = { id = "org.jetbrains.kotlinx.kover", version.ref = "kover" }
#publishing
multiplatform-swiftpackage = { id = "io.github.luca992.multiplatform-swiftpackage", version.ref = "multiplatform-swiftpackage" }

touchlab-kmmbridge = { id = "co.touchlab.kmmbridge", version.ref = "touchlab-kmmbridge" }


[versions]

kotlin = "2.0.0-Beta2"
Expand All @@ -30,6 +33,7 @@ assertj-core = "3.24.2"

# plugins
multiplatform-swiftpackage = "2.2.1"
touchlab-kmmbridge = "0.5.1"

[libraries]

Expand Down
18 changes: 18 additions & 0 deletions shared/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ plugins {
alias(libs.plugins.kotlinx.serialization)
alias(libs.plugins.multiplatform.swiftpackage)
alias(libs.plugins.kover)
alias(libs.plugins.touchlab.kmmbridge)
`maven-publish`
}

kotlin {
Expand Down Expand Up @@ -49,6 +51,22 @@ multiplatformSwiftPackage {
}
}

addGithubPackagesRepository()

kmmbridge {
mavenPublishArtifacts()
spm()
// spm {
// swiftToolsVersion = "5.9"
// platforms {
// iOS { v("14") }
// macOS { v("13") }
// watchOS { v("7") }
// tvOS { v("14") }
// }
// }
}

tasks {
named<Test>("jvmTest") {
useJUnitPlatform()
Expand Down

0 comments on commit 0ad3947

Please sign in to comment.