-
Notifications
You must be signed in to change notification settings - Fork 1
56 lines (53 loc) · 1.52 KB
/
publish.yml
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
name: Publish
on:
create:
tags:
- '^[0-9]+\.[0-9]+\.[0-9]+$'
push:
branches:
- publish-spm
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: "Clone repo"
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: "Set up Adopt OpenJDK 17"
uses: actions/setup-java@v3
with:
distribution: adopt
java-version: 17
- name: "Detekt"
run: sh gradlew detekt
- name: "KtLint"
run: sh gradlew ktlintCheck
build:
needs: lint
runs-on: macos-latest
steps:
- name: "Clone repo"
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: "Set up Adopt OpenJDK 17"
uses: actions/setup-java@v3
with:
distribution: adopt
java-version: 17
- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v1
publish:
needs: build
permissions:
contents: write
packages: write
uses: touchlab/KMMBridgeGithubWorkflow/.github/workflows/[email protected]
with:
runsOn: "macOS-14"
jvmVersion: 17
versionBaseProperty: LIBRARY_VERSION
publishTask: kmmBridgePublish publishKotlinMultiplatformPublicationToGitHubPackagesRepository publishAndroidReleasePublicationToGitHubPackagesRepository
secrets:
gradle_params: -PGITHUB_PUBLISH_USER=${{ secrets.GITHUB_ACTOR }} -PGITHUB_PUBLISH_TOKEN=${{ secrets.GITHUB_TOKEN }} -PGITHUB_REPO=https://github.com/Airthings/KmpLog.git