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
29 changes: 29 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,7 @@ jobs:
# The app version names the assets — GITHUB_REF_NAME is a branch on
# dispatch runs (e.g. `feature/x` → a slash → unwritable filenames).
- name: Stage Android bundles
id: android-bundles
run: |
set -euo pipefail
out="apps/desktop/src-tauri/gen/android/app/build/outputs"
Expand All @@ -339,6 +340,34 @@ jobs:
find "$out/apk" -name '*universal*.apk' -exec cp {} "staging/ThinkbrainNotes-${version}-android-universal.apk" \;
echo "Staged bundles:"
ls -la staging/
# Expose the production-signed universal APK so the emulator smoke
# test below installs the exact artifact users would download.
apk="staging/ThinkbrainNotes-${version}-android-universal.apk"
test -s "$apk"
echo "apk=$apk" >> "$GITHUB_OUTPUT"

# A green compile is not proof the app starts — the v0.5.0 APK built fine
# but aborted in Rust_onCreate on every cold launch. Boot an emulator and
# smoke-test the production-signed APK BEFORE any artifact or release
# upload so a failing startup check blocks Android publication.
- name: Enable KVM group permissions
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: Smoke-test minified Android release
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 35
target: google_apis
arch: x86_64
ram-size: 2048M
disable-animations: true
script: |
adb install -r "${{ steps.android-bundles.outputs.apk }}"
pnpm android:smoke
timeout-minutes: 15

- name: Upload workflow artifacts
uses: actions/upload-artifact@v4
Expand Down
2 changes: 1 addition & 1 deletion knip.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"$schema": "https://unpkg.com/knip@6/schema.json",
"$schema": "./node_modules/knip/schema.json",
"ignore": [".agents/**", "examples/**"],
"workspaces": {
".": {
Expand Down
Loading