2024-03-23 13:59:01 +01:00

44 lines
974 B
YAML

name: CI-Android APK
env:
main_project_module: app
playstore_name: KeepassFidelity
on:
push:
branches: [ release ]
pull_request:
branches: [ release ]
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: gradle/wrapper-validation-action@v2
- name: create and checkout branch
if: github.event_name == 'pull_request'
env:
BRANCH: ${{ github.head_ref }}
run: git checkout -B "$BRANCH"
- name: set up JDK
uses: actions/setup-java@v4
with:
java-version: 17
distribution: "temurin"
cache: 'gradle'
- name: Build APK
run: ./gradlew assemble
- name: Upload APK
uses: actions/upload-artifact@v4
with:
name: app
path: app/build/outputs/apk/release/*.apk