Files
OVERWATCH/.github/workflows/release.yml
T
KaraZajac ef68394080
Build APK / build (push) Waiting to run
ci: build debug APK and publish release on tag via GitHub Actions
release.yml builds :app:assembleDebug (JDK 17 + Android SDK) and uploads the
APK as an artifact on every run; on a v* tag push it also creates a GitHub
Release with the APK attached. No build-time secrets — the app carries no
key/token.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015jgJnzMr2bdNuWcDX2xRUR
2026-07-13 00:26:07 -04:00

52 lines
1.2 KiB
YAML

name: Build APK
on:
push:
tags:
- 'v*'
workflow_dispatch:
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- 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: |
chmod +x ./gradlew
./gradlew :app:assembleDebug --stacktrace --no-daemon
- name: Stage APK
run: |
mkdir -p out
cp app/build/outputs/apk/debug/app-debug.apk "out/OVERWATCH-${GITHUB_REF_NAME}.apk"
# Uploaded on every run (incl. workflow_dispatch) so a build can be
# validated without cutting a release.
- name: Upload APK artifact
uses: actions/upload-artifact@v4
with:
name: overwatch-apk
path: out/*.apk
# Only tag pushes (v*) create a GitHub Release with the APK attached.
- name: Publish Release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v2
with:
files: out/*.apk
generate_release_notes: true