mirror of
https://github.com/meowarex/rl-mobile.git
synced 2026-06-17 21:13:11 +10:00
Update Actions CI
This commit is contained in:
+28
-23
@@ -1,40 +1,45 @@
|
||||
name: Build Debug App
|
||||
name: Build Release App
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
workflow_call:
|
||||
secrets:
|
||||
keyAlias:
|
||||
required: true
|
||||
keyPassword:
|
||||
required: true
|
||||
keystorePassword:
|
||||
required: true
|
||||
keystore:
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Setup JDK 21
|
||||
uses: actions/setup-java@v4
|
||||
- uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: 21
|
||||
distribution: zulu
|
||||
|
||||
- name: Setup Gradle
|
||||
uses: gradle/actions/setup-gradle@v4
|
||||
with:
|
||||
cache-read-only: ${{ github.event_name == 'pull_request' }}
|
||||
- uses: gradle/actions/setup-gradle@v4
|
||||
|
||||
- name: Build with Gradle
|
||||
- name: Build
|
||||
working-directory: Manager
|
||||
run: ./gradlew :app:assembleDebug --stacktrace
|
||||
env:
|
||||
SIGNING_KEY_ALIAS: ${{ secrets.keyAlias }}
|
||||
SIGNING_KEY_PASSWORD: ${{ secrets.keyPassword }}
|
||||
SIGNING_STORE_PASSWORD: ${{ secrets.keystorePassword }}
|
||||
SIGNING_STORE_FILE: ${{ github.workspace }}/release.keystore
|
||||
RELEASE: true
|
||||
run: |
|
||||
echo "${{ secrets.keystore }}" | base64 -d > ${{ github.workspace }}/release.keystore
|
||||
./gradlew :app:packageRelease --stacktrace
|
||||
rm ${{ github.workspace }}/release.keystore
|
||||
|
||||
- name: Upload artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: app
|
||||
name: rl-mobile-artifacts
|
||||
if-no-files-found: error
|
||||
path: Manager/app/build/outputs/apk/debug/app-debug.apk
|
||||
path: Manager/app/build/outputs/apk/release/app-release.apk
|
||||
|
||||
Reference in New Issue
Block a user