CI: build debug APK on push to main and upload as artifact

This commit is contained in:
Brendan Greenlee 2026-08-01 15:14:07 +00:00
parent 7a380c40ed
commit 95069ff263

49
.github/workflows/build-apk.yml vendored Normal file
View file

@ -0,0 +1,49 @@
name: Build APK
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
concurrency:
group: build-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Build debug APK
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: '17'
- name: Set up Android SDK
uses: android-actions/setup-android@v3
- name: Build debug APK
run: |
./gradlew :app:assembleThirdPartyDebug --no-daemon --stacktrace
- name: Upload APK artifact
uses: actions/upload-artifact@v4
with:
name: openclaw-android-heartbeat-debug
path: app/build/outputs/apk/thirdParty/debug/*.apk
if-no-files-found: error
retention-days: 30
# Future: release builds — add keystore secrets (ANDROID_KEYSTORE_BASE64,
# ANDROID_KEYSTORE_PASSWORD, ANDROID_KEY_ALIAS, ANDROID_KEY_PASSWORD) to
# repo secrets, then add a `release` job that signs and uploads to
# GitHub Releases.