Skip to content

Configure GitHub Actions for release builds#44

Open
qiarie wants to merge 43 commits into
mainfrom
github-ci
Open

Configure GitHub Actions for release builds#44
qiarie wants to merge 43 commits into
mainfrom
github-ci

Conversation

@qiarie
Copy link
Copy Markdown
Contributor

@qiarie qiarie commented May 12, 2026

Fixes #43

  • All CI build checks pass e.g. Tests
  • Appropriate changes to documentation are included in the PR

@qiarie qiarie requested review from ellykits and ndegwamartin May 12, 2026 07:08
Comment thread .github/workflows/release.yml Outdated
Comment thread .github/workflows/release.yml
Comment thread .github/workflows/release.yml Outdated
Comment thread .github/workflows/release.yml
Comment thread ohs-player-reference-app/build.gradle.kts Outdated
@ellykits
Copy link
Copy Markdown
Collaborator

How do we intend to deploy the web version for the Kotlin Multiplatform @qiarie? Can you trigger a sample release for purposes of testing we can delete the tag afterwards.

qiarie and others added 3 commits May 13, 2026 14:33
Co-authored-by: Elly Kitoto <junkmailstoelly@gmail.com>
Co-authored-by: Elly Kitoto <junkmailstoelly@gmail.com>
Co-authored-by: Elly Kitoto <junkmailstoelly@gmail.com>
@qiarie qiarie changed the title Configure GitHub CI for release builds Configure GitHub Actions for release builds May 13, 2026
@qiarie qiarie temporarily deployed to github-pages May 13, 2026 12:31 — with GitHub Actions Inactive
qiarie added 19 commits May 13, 2026 15:43
- Closed shell-injection sink in preflight
- Hardened env-var handling (VERSION_NAME/VERSION_CODE blank-safe
- composePackageVersion fails loudly on malformed input)
- Widened tag regex to Semantic Versioning-legal hyphen suffixes
- Added count-check to the desktop matrix output
- Updated spotless job fetch-depth: 0 so ratchetFrom = "origin/main" resolves
actions/checkout only populates the ref it checks out — refs/pull/<N>/merge
for PRs - so refs/remotes/origin/main is never created and spotless'
ratchetFrom = "origin/main" fails at task-graph construction. Switch the
spotless job to fetch-depth: 0 and add an explicit fetch that creates
the missing ref
- Upgrade Kotlin to 2.3.21
- Disable unstable JS and Android-host test tasks
@qiarie
Copy link
Copy Markdown
Contributor Author

qiarie commented May 29, 2026

How do we intend to deploy the web version for the Kotlin Multiplatform @qiarie? Can you trigger a sample release for purposes of testing we can delete the tag afterwards.

Refer to this test pre-release Release v1.0.0-test.4

@qiarie qiarie enabled auto-merge (squash) May 29, 2026 16:11
Comment thread .github/workflows/ci.yml Outdated
Comment on lines +56 to +57
# Each leg gets its own 16 GB runner, so the JS and Wasm test-executable
# compiles don't compete with each other for Kotlin daemon heap.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete comment

Comment thread .github/workflows/ci.yml Outdated
Comment on lines +87 to +88
# compileTestDevelopmentExecutableKotlinJs has historically OOMed
# at 6g; give the Kotlin daemon more room only for this leg.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete comment. This can be inferred from the setting.

Comment thread .github/workflows/ci.yml
Comment on lines +75 to +77
tasks: >-
:ohs-player-library:assembleAndroidMain
:ohs-player-reference-app:lintDebug
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the intention for these two tasks? They serve different purposes. The assembleAndroidMain should be used to compile, process resources and package apk artifacts, whereas lintDebug is used for analyzing code, for bugs, performance issues, security and styling deviations. Those two cases differ I think you should decide on which one to keep (build and package or debug variant analysis).

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check out this comment:

ohs-player-library uses the androidKotlinMultiplatformLibrary plugin, which doesn't register lintDebug - assembleAndroidMain is the closest "compile + verify the Android variant" task it exposes. ohs-player-reference-app uses classic androidTarget and keeps lintDebug.

ohs-player-library uses the com.android.kotlin.multiplatform.library plugin, which doesn't register a lintDebug task, so lint isn't available there. assembleAndroidMain is the closest task it exposes that compiles and verifies the Android variant. ohs-player-reference-app is still a classic com.android.application + androidTarget, which does have lintDebug.

The goal of this leg isn't strictly "build" or strictly "analyze" - it's "verify the Android variant of both modules is healthy using whatever each module's plugin exposes": a compile/package check on the library and lint analysis on the app.

This asymmetry resolves itself during the AGP9 migration. The app will be split into a thin com.android.application module (androidApp) on top of KMP library modules, at which point ohs-player-reference-app becomes a com.android.kotlin.multiplatform.library and loses lintDebug - same as the library today. It will change to

tasks: >-
  :ohs-player-library:assembleAndroidMain
  :ohs-player-reference-app:assembleAndroidMain   # both KMP modules: compile + verify
  :androidApp:lintDebug                           # lint on the one real Android app module

I'd lean towards leaving this leg as-is until the AGP9 migration is ready.

Comment thread .github/workflows/ci.yml Outdated
Comment on lines +96 to +97
# Same reason as the js leg: compileTestDevelopmentExecutableKotlinWasmJs
# exhausts 6g; needs more daemon heap, but only on this runner.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be inferred from the setting below, no need to add this comment, the alternative make it brief.

Comment thread .github/workflows/ci.yml Outdated
Comment on lines +134 to +138
# iOS targets can't be compiled on Linux. macos-latest billing is 10× so
# keep each leg focused on a single arch so the K/N compiler isn't
# fighting itself for the 14 GB runner. Debug link is sufficient to
# prove iOS code compiles and links; release link belongs in release.yml
# whenever iOS distribution is added.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Paraphrase this comment and make it brief.

Comment thread ohs-player-reference-app/build.gradle.kts Outdated
Comment thread ohs-player-reference-app/build.gradle.kts Outdated
Comment on lines 166 to 167
sourceCompatibility = JavaVersion.VERSION_11
targetCompatibility = JavaVersion.VERSION_11
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to upgrade this to at least Java 17. I'm okay doing that in a followup PR.

Copy link
Copy Markdown
Contributor Author

@qiarie qiarie Jun 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can leave this to the AGP9 migration PR. We can also agree on the runtime floor to support then.

Comment on lines +173 to +177
// WiX/MSI requires a strict MAJOR.MINOR.PATCH numeric version, so strip any
// Semantic Version pre-release suffix (e.g. -alpha.1) from VERSION_NAME for the desktop
// installers. Android's versionName keeps the suffix; this drift is intentional.
// Uses the providers API so the configuration cache tracks VERSION_NAME as a
// declared input.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Improve this comment and provide example how the new version name will be on the respective platforms with before and after (stripping) versions.

Comment on lines +190 to +191
// Same as in ohs-player-library: Compose UI tests in commonTest don't run
// cleanly on Android-host JVM (needs Robolectric + per-class @RunWith) nor in
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not think we need Robolectric with Compose multiplatform to run the UI tests. Refer to Compose Multiplatform UI test. We should adopt that.

qiarie and others added 5 commits June 2, 2026 12:14
Co-authored-by: Elly Kitoto <junkmailstoelly@gmail.com>
Co-authored-by: Elly Kitoto <junkmailstoelly@gmail.com>
- Update comments
- Disable failing JS/Wasm/Android-host test tasks only on CI
- Rename helpers for clarity: envOrAbsent -> nonBlankEnv, envOrFile -> envOrKeystore
- Expand build-script comments
- Update release.yml workflow_dispatch dry-run description
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add GitHub action release pipeline plus CI setup

2 participants