Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 22 additions & 57 deletions .github/workflows/DEPLOY.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,71 +18,36 @@ on:
env:
CI: true
FORCED_VERSION: ${{ inputs.forced_version || github.ref }}
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGKEY }}
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGPASSWORD }}
SONATYPE_USERNAME: ${{ secrets.SONATYPEUSERNAME }}
SONATYPE_PASSWORD: ${{ secrets.SONATYPEPASSWORD }}
JAVA_VERSION: 17
# Vanniktech maven-publish plugin reads these exact Gradle project property names for signing
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGKEY }}
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGPASSWORD }}
# Vanniktech maven-publish plugin reads these for Central Portal auth
ORG_GRADLE_PROJECT_mavenCentralUsername: ${{ secrets.ORG_KORGE_SONATYPE_USERNAME }}
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.ORG_KORGE_SONATYPE_PASSWORD }}
JAVA_VERSION: 21
JAVA_DISTRIBUTION: zulu

jobs:
##start:
## runs-on: ubuntu-latest
## outputs:
## stagedRepositoryId: ${{ steps.releaseStep.outputs.stagedRepositoryId }}
## steps:
## - { name: Checkout, uses: actions/checkout@v3 }
## - { name: Set up JDK, uses: actions/setup-java@v3, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } }
## - { name: Prepare Gradle, uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 } # https://github.com/gradle/actions/releases/tag/v3.5.0
## - { id: releaseStep, name: Start Maven Central Staging Repository, run: ./gradlew --no-configuration-cache startReleasingMavenCentral }

publish:
strategy:
fail-fast: false
matrix:
include:
- { os: ubuntu-latest, publishTask: "publishLinuxX64PublicationToMavenLocal publishLinuxArm64PublicationToMavenLocal" }
- { os: ubuntu-latest, publishTask: "publishMingwX64PublicationToMavenLocal" }
- { os: ubuntu-latest, publishTask: "publishAndroidDebugPublicationToMavenLocal publishAndroidReleasePublicationToMavenLocal" }
- { os: ubuntu-latest, publishTask: "publishKotlinMultiplatformPublicationToMavenLocal publishJvmPublicationToMavenLocal" }
- { os: ubuntu-latest, publishTask: "publishJsPublicationToMavenLocal publishWasmJsPublicationToMavenLocal" }
- { os: macos-13, publishTask: "publishMacosX64PublicationToMavenLocal publishMacosArm64PublicationToMavenLocal" }
- { os: macos-13, publishTask: "publishTvosArm64PublicationToMavenLocal publishTvosSimulatorArm64PublicationToMavenLocal publishTvosX64PublicationToMavenLocal" }
- { os: macos-13, publishTask: "publishIosArm64PublicationToMavenLocal publishIosSimulatorArm64PublicationToMavenLocal publishIosX64PublicationToMavenLocal" }
- { os: macos-13, publishTask: "publishWatchosArm64PublicationToMavenLocal publishWatchosArm32PublicationToMavenLocal publishWatchosDeviceArm64PublicationToMavenLocal publishWatchosSimulatorArm64PublicationToMavenLocal" }
- { os: ubuntu-latest, publishTask: "publishLinuxX64PublicationToMavenCentral publishLinuxArm64PublicationToMavenCentral" }
- { os: ubuntu-latest, publishTask: "publishMingwX64PublicationToMavenCentral" }
- { os: ubuntu-latest, publishTask: "publishAndroidReleasePublicationToMavenCentral" }
- { os: ubuntu-latest, publishTask: "publishKotlinMultiplatformPublicationToMavenCentral publishJvmPublicationToMavenCentral" }
- { os: ubuntu-latest, publishTask: "publishJsPublicationToMavenCentral publishWasmJsPublicationToMavenCentral" }
- { os: macos-latest, publishTask: "publishMacosX64PublicationToMavenCentral publishMacosArm64PublicationToMavenCentral" }
- { os: macos-latest, publishTask: "publishTvosArm64PublicationToMavenCentral publishTvosSimulatorArm64PublicationToMavenCentral publishTvosX64PublicationToMavenCentral" }
- { os: macos-latest, publishTask: "publishIosArm64PublicationToMavenCentral publishIosSimulatorArm64PublicationToMavenCentral publishIosX64PublicationToMavenCentral" }
- { os: macos-latest, publishTask: "publishWatchosArm64PublicationToMavenCentral publishWatchosArm32PublicationToMavenCentral publishWatchosDeviceArm64PublicationToMavenCentral publishWatchosSimulatorArm64PublicationToMavenCentral" }
timeout-minutes: 300
runs-on: ${{ matrix.os }}
##needs: [start]
##env: { stagedRepositoryId: "${{ needs.start.outputs.stagedRepositoryId }}" }
steps:
##- { name: Print stagedRepositoryId=$stagedRepositoryId, run: "echo 'stagedRepositoryId: $stagedRepositoryId'" }
- name: Replace MavenLocal with MavenLocal
id: replace
run: |
publishTaskLocal=$(echo "${{ matrix.publishTask }}" | tr -d '\n')
publishTaskRepository=$(echo "${{ matrix.publishTask }}" | sed 's/MavenLocal/MavenRepository/g' | tr -d '\n')
echo "publishTaskLocal=${publishTaskLocal}" >> $GITHUB_ENV
echo "publishTaskRepository=${publishTaskRepository}" >> $GITHUB_ENV
- { name: Print publishTaskLocal, run: "echo 'publishTaskLocal: ${{ env.publishTaskLocal }}'" }
- { name: Print publishTaskRepository, run: "echo 'publishTaskRepository: ${{ env.publishTaskRepository }}'" }
- { name: Checkout, uses: actions/checkout@v3 }
- { name: Use Node.js 20.x, uses: actions/setup-node@v3, with: { node-version: 20.x } }
- { name: Set up JDK, uses: actions/setup-java@v3, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } }
- { name: Prepare Gradle, uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 } # https://github.com/gradle/actions/releases/tag/v3.5.0
- { name: Initialize Gradle, run: ./gradlew --no-configuration-cache }
- { name: Publish Publications To Maven Local, run: "./gradlew --no-configuration-cache --parallel ${{ env.publishTaskLocal }}" }
- { name: Start Maven Central Staging Repository, run: ./gradlew --no-configuration-cache startReleasingMavenCentral }
- { name: Publish Publications To Maven Repository, run: "./gradlew --no-configuration-cache --parallel --max-workers=8 ${{ env.publishTaskRepository }}" }
- { name: Release to Maven Central, run: ./gradlew --no-configuration-cache releaseMavenCentral }

##finalize:
## runs-on: ubuntu-latest
## needs: [start, publish]
## env: { stagedRepositoryId: "${{ needs.start.outputs.stagedRepositoryId }}" }
## steps:
## - { name: Checkout, uses: actions/checkout@v3 }
## - { name: Use Node.js 20.x, uses: actions/setup-node@v3, with: { node-version: 20.x } }
## - { name: Set up JDK, uses: actions/setup-java@v3, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } }
## - { name: Prepare Gradle, uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 } # https://github.com/gradle/actions/releases/tag/v3.5.0
## - { name: Initialize Gradle, run: ./gradlew --no-configuration-cache }
## - { name: Release to Maven Central, run: ./gradlew --no-configuration-cache releaseMavenCentral }
- { name: "Checkout", uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd } # https://github.com/actions/checkout/releases/tag/v6.0.2
- { name: "Use Node.js 24.x", uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f, with: { node-version: 24.x } } # https://github.com/actions/setup-node/releases/tag/v6.3.0
- { name: "Set up JDK", uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } } # https://github.com/actions/setup-java/releases/tag/v5.2.0
- { name: "Prepare Gradle", uses: gradle/actions/setup-gradle@39e147cb9de83bb9910b8ef8bd7fff0ee20fcd6f } # https://github.com/gradle/actions/releases/tag/v6.0.1
- { name: "Initialize Gradle", run: "./gradlew --no-configuration-cache" }
- { name: "Publish to Maven Central", run: "./gradlew --no-configuration-cache --parallel --max-workers=8 ${{ matrix.publishTask }}" }
Comment thread
jobe-m marked this conversation as resolved.
18 changes: 9 additions & 9 deletions .github/workflows/DOCS.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@ concurrency:
env:
CI: true
FORCED_VERSION: ${{ inputs.forced_version || github.ref }}
JAVA_VERSION: 17
JAVA_VERSION: 21
JAVA_DISTRIBUTION: zulu

jobs:
publish:
timeout-minutes: 300
runs-on: ubuntu-latest
steps:
- { name: Checkout, uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 } # https://github.com/actions/checkout/releases/tag/v4.1.7
- { name: Set up JDK, uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } } # https://github.com/actions/setup-java/releases/tag/v4.2.1
- { name: Use Node.js 20.x, uses: actions/setup-node@1e60f620b9541d16bece96c5465dc8ee9832be0b, with: { node-version: 20.x } } # https://github.com/actions/setup-node/releases/tag/v4.0.3
- { name: Prepare Gradle, uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 } # https://github.com/gradle/actions/releases/tag/v3.5.0
- { name: Initialize Gradle, run: ./gradlew --no-configuration-cache }
- { name: Build Documentation, run: ./gradlew --no-configuration-cache dokkaHtmlMultiModule }
- { name: Upload artifact, uses: actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa, with: { path: 'build/dokka/htmlMultiModule' } } # https://github.com/actions/upload-pages-artifact/releases/tag/v3.0.1
- { name: Deploy 🚀 to GitHub Pages, id: deployment, uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e} # https://github.com/actions/deploy-pages/releases/tag/v4.0.5
- { name: "Checkout", uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd } # https://github.com/actions/checkout/releases/tag/v6.0.2
- { name: "Use Node.js 24.x", uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f, with: { node-version: 24.x } } # https://github.com/actions/setup-node/releases/tag/v6.3.0
- { name: "Set up JDK", uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } } # https://github.com/actions/setup-java/releases/tag/v5.2.0
- { name: "Prepare Gradle", uses: gradle/actions/setup-gradle@39e147cb9de83bb9910b8ef8bd7fff0ee20fcd6f } # https://github.com/gradle/actions/releases/tag/v6.0.1
- { name: "Initialize Gradle", run: "./gradlew --no-configuration-cache" }
- { name: "Build Documentation", run: "./gradlew --no-configuration-cache dokkaGenerateHtml" }
- { name: "Upload artifact", uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b, with: { path: 'korlibs-image-core/build/dokka/html' } } # https://github.com/actions/upload-pages-artifact/releases/tag/v4.0.0
- { name: "Deploy 🚀 to GitHub Pages", id: deployment, uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 } # https://github.com/actions/deploy-pages/releases/tag/v5.0.0
38 changes: 19 additions & 19 deletions .github/workflows/TEST.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,42 +26,42 @@ concurrency:
env:
CI: true

JAVA_VERSION: 17
JAVA_DISTRIBUTION: temurin
JAVA_VERSION: 21
JAVA_DISTRIBUTION: zulu

jobs:
test:
strategy:
#fail-fast: true # Once working, comment this
fail-fast: true
matrix:
include:
- { outputKey: testMacosIos, os: macos-latest, testTask: jvmTest macosArm64Test iosSimulatorArm64Test, buildTasks: publishMacosX64PublicationToMavenLocal }
- { outputKey: testJsAndroid, os: ubuntu-latest, testTask: "wasmBrowserTest", buildTasks: "jsBrowserTest jsDenoTest", enableAndroid: true }
- { outputKey: testJsAndroid, os: ubuntu-latest, testTask: "wasmBrowserTest", buildTasks: "jsBrowserTest jsDenoTest", upgradeYarnLock: true, enableAndroid: true }
- { outputKey: testLinux, os: ubuntu-latest, testTask: apiCheck jvmTest linuxX64Test, precompileTask: compileTestKotlinJvm, enableCodecov: true, e2e: true }
- { outputKey: testWindows, os: windows-latest, testTask: jvmTest mingwX64Test jsDenoTest, precompileTask: compileTestKotlinJvm }
#if: ${{ needs.changes.outputs[matrix.outputKey] == 'true' }}
- { outputKey: testWindows, os: windows-latest, testTask: jvmTest mingwX64Test jsDenoTest, precompileTask: compileTestKotlinJvm, upgradeYarnLock: true }
timeout-minutes: 60
runs-on: ${{ matrix.os }}
steps:
- { uses: actions/checkout@v4 }
- { name: Use Node.js 20.x, uses: actions/setup-node@v4, with: { node-version: 20.x } }
- { name: Setup Deno, uses: denoland/setup-deno@v1, with: { deno-version: "1.44.4" } }
- { name: Set up JDK, uses: actions/setup-java@v4, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}", cache: 'gradle' } }
#- { name: Prepare Gradle, uses: gradle/actions/setup-gradle@af1da67850ed9a4cedd57bfd976089dd991e2582 } # https://github.com/gradle/actions/releases/tag/v4.0.0
- { name: "Cache Kotlin/Native .konan folder", uses: actions/cache@v4, with: { path: "~/.konan", key: "${{ runner.os }}-konan", restore-keys: "${{ runner.os }}-konan" } }
- { name: "Checkout", uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd } # https://github.com/actions/checkout/releases/tag/v6.0.2
- { name: "Use Node.js 24.x", uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f, with: { node-version: 24.x } } # https://github.com/actions/setup-node/releases/tag/v6.3.0
- { name: "Setup Deno", uses: denoland/setup-deno@e95548e56dfa95d4e1a28d6f422fafe75c4c26fb, with: { deno-version: "2.7.11" } } # https://github.com/denoland/setup-deno/releases/tag/v2.0.3
- { name: "Set up JDK", uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654, with: { distribution: "${{ env.JAVA_DISTRIBUTION }}", java-version: "${{ env.JAVA_VERSION }}" } } # https://github.com/actions/setup-java/releases/tag/v5.2.0
- { name: "Prepare Gradle", uses: gradle/actions/setup-gradle@39e147cb9de83bb9910b8ef8bd7fff0ee20fcd6f } # https://github.com/gradle/actions/releases/tag/v6.0.1
- { name: "Cache Kotlin/Native .konan folder", uses: actions/cache@668228422ae6a00e4ad889ee87cd7109ec5666a7, with: { path: "~/.konan", key: "${{ runner.os }}-konan", restore-keys: "${{ runner.os }}-konan" } } # https://github.com/actions/cache/releases/tag/v5.0.4
- { name: Start gradle, run: ./gradlew }
- { if: "${{ matrix.upgradeYarnLock }}", name: "Upgrade yarn lock", run: "./gradlew kotlinUpgradeYarnLock" }
- { if: "${{ matrix.precompileTask }}", name: "Building ${{ matrix.precompileTask }} classes", run: "./gradlew --stacktrace ${{ matrix.precompileTask }}" }
- { if: "${{ matrix.testTask }}", name: "Run ${{ matrix.testTask }} tests", run: "./gradlew ${{ matrix.testTask }}" }
- { if: "${{ matrix.buildTasks }}", name: "Run ${{ matrix.buildTasks }}", run: "./gradlew ${{ matrix.buildTasks }}" }
- name: Enable KVM
- name: "Enable KVM"
if: "${{ matrix.enableAndroid }}"
run: |
echo 'KERNEL=="kvm", GROUP="kvm", MODE="0666", OPTIONS+="static_node=kvm"' | sudo tee /etc/udev/rules.d/99-kvm4all.rules
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- { name: "Run Android Tests", if: "${{ matrix.enableAndroid }}", uses: reactivecircus/android-emulator-runner@v2, with: { "api-level": 21, "script": "./gradlew connectedCheck lintDebug" } }
- { name: Archive Test Results, if: failure(), uses: actions/upload-artifact@v4, with: { name: "test-results-${{ matrix.outputKey }}", retention-days: 21, path: "**/build/reports", if-no-files-found: ignore } }
- { if: "${{ matrix.e2e }}", name: Publish to maven local, run: ./gradlew publishJvmLocal publishKotlinMultiplatformPublicationToMavenLocal }
- { if: "${{ matrix.enableCodecov }}", name: Code coverage, run: ./gradlew koverXmlReport }
- { if: "${{ matrix.enableCodecov }}", name: "Upload coverage reports to Codecov", uses: "codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673", with: { token: "${{ secrets.CODECOV_TOKEN }}" } } # https://github.com/codecov/codecov-action/releases/tag/v4.5.0
- { name: Stop daemon, run: ./gradlew --stop }
- { name: "Run Android Tests", if: "${{ matrix.enableAndroid }}", uses: reactivecircus/android-emulator-runner@e89f39f1abbbd05b1113a29cf4db69e7540cae5a, with: { "api-level": 21, "script": "./gradlew connectedCheck lintDebug" } } # https://github.com/ReactiveCircus/android-emulator-runner/releases/tag/v2.37.0
- { name: "Archive Test Results", if: failure(), uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f, with: { name: "test-results-${{ matrix.outputKey }}", retention-days: 21, path: "**/build/reports", if-no-files-found: ignore } } # https://github.com/actions/upload-artifact/releases/tag/v7.0.0
- { name: "Publish to maven local", if: "${{ matrix.e2e }}", run: "./gradlew publishJvmLocal publishKotlinMultiplatformPublicationToMavenLocal" }
- { name: "Code coverage", if: "${{ matrix.enableCodecov }}", run: "./gradlew koverXmlReport" }
- { name: "Upload coverage reports to Codecov", if: "${{ matrix.enableCodecov }}", uses: codecov/codecov-action@57e3a136b779b570ffcdbf80b3bdc90e7fab3de2, with: { token: "${{ secrets.CODECOV_TOKEN }}" } } # https://github.com/codecov/codecov-action/releases/tag/v6.0.0
- { name: "Stop daemon", run: "./gradlew --stop" }
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- BADGES -->
[![test](https://github.com/korlibs/korlibs-image-core/actions/workflows/TEST.yml/badge.svg)](https://github.com/korlibs/korlibs-image-core/actions/workflows/TEST.yml)
[![codecov](https://codecov.io/gh/korlibs/korlibs-image-core/graph/badge.svg)](https://codecov.io/gh/korlibs/korlibs-image-core)
[![Maven Central Version](https://img.shields.io/maven-central/v/com.soywiz/korlibs-image-core)](https://central.sonatype.com/artifact/com.soywiz/korlibs-image-core)
[![Maven Central Version](https://img.shields.io/maven-central/v/org.korge/korlibs-image-core)](https://central.sonatype.com/artifact/org.korge/korlibs-image-core)
[![Discord](https://img.shields.io/discord/728582275884908604?logo=discord&label=Discord)](https://discord.korge.org/)
[![KDoc](https://img.shields.io/badge/docs-kdoc-blue)](https://korlibs.github.io/korlibs-image-core/)
[![Documentation](https://img.shields.io/badge/docs-documentation-purple)](https://docs.korge.org/image-core/)
Expand Down
Loading
Loading