|
|
|
@ -1,42 +1,48 @@
|
|
|
|
|
name: Generate APK Debug
|
|
|
|
|
|
|
|
|
|
on:
|
|
|
|
|
# Triggers the workflow on push or pull request events but only for default and protected branches
|
|
|
|
|
push:
|
|
|
|
|
branches:
|
|
|
|
|
- master
|
|
|
|
|
- '*'
|
|
|
|
|
paths-ignore:
|
|
|
|
|
- '**.md'
|
|
|
|
|
pull_request:
|
|
|
|
|
branches:
|
|
|
|
|
- master
|
|
|
|
|
- '*'
|
|
|
|
|
paths-ignore:
|
|
|
|
|
- '**.md'
|
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
build:
|
|
|
|
|
|
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
permissions:
|
|
|
|
|
contents: read
|
|
|
|
|
packages: write
|
|
|
|
|
|
|
|
|
|
steps:
|
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
|
- name: Check out repository
|
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
|
with:
|
|
|
|
|
submodules: true
|
|
|
|
|
|
|
|
|
|
- name: Set Up JDK
|
|
|
|
|
- name: Set up Java 11
|
|
|
|
|
uses: actions/setup-java@v3
|
|
|
|
|
with:
|
|
|
|
|
distribution: 'zulu'
|
|
|
|
|
java-version: '11'
|
|
|
|
|
java-version: 11
|
|
|
|
|
distribution: 'adopt'
|
|
|
|
|
cache: gradle
|
|
|
|
|
|
|
|
|
|
- name: Change wrapper permissions
|
|
|
|
|
run: chmod +x ./gradlew
|
|
|
|
|
|
|
|
|
|
- name: Run tests
|
|
|
|
|
run: ./gradlew test
|
|
|
|
|
|
|
|
|
|
# Create APK Debug
|
|
|
|
|
- name: Build apk debug
|
|
|
|
|
run: ./gradlew app:assembleDefaultDebug
|
|
|
|
|
|
|
|
|
|
- name: Build apk fdroid-debug
|
|
|
|
|
run: ./gradlew app:assembleFdroidDebug
|
|
|
|
|
|
|
|
|
|
# Upload Artifact Build
|
|
|
|
|
# Noted For Output [module-name]/build/outputs/apk
|
|
|
|
|
- name: Upload apk debug
|
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
|
with:
|
|
|
|
|