-
Notifications
You must be signed in to change notification settings - Fork 2
46 lines (38 loc) · 1.29 KB
/
build-apk.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: BUILD APK
on:
push:
branches:
- main
jobs:
apk-build:
runs-on: ubuntu-latest
timeout-minutes: 60
env:
ANDROID_RELEASE_KEYSTORE_BASE64: ${{ secrets.ANDROID_RELEASE_KEYSTORE_BASE64 }}
ANDROID_RELEASE_KEYSTORE_PWD: ${{ secrets.ANDROID_RELEASE_KEYSTORE_PWD }}
ANDROID_RELEASE_KEY_ALIAS: ${{ secrets.ANDROID_RELEASE_KEY_ALIAS }}
ANDROID_RELEASE_KEY_PWD: ${{ secrets.ANDROID_RELEASE_KEY_PWD }}
steps:
- uses: actions/checkout@v3
- name: Setup JDK
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Decode Keystore
run: |
echo $ANDROID_RELEASE_KEYSTORE_BASE64 > keystore_base64.txt
base64 -d keystore-b64.txt > fubukidaze-android-release
- name: Assemble Release
run: |
./gradlew :composeApp:assembleRelease
- name: Get Release APK Path
id: releaseApk
run: echo "apkfile=$(find composeApp/build/outputs/apk/release/*.apk)" >> $GITHUB_OUTPUT
- name: Upload APK to Artifacts
uses: actions/upload-artifact@v3
with:
name: release-artifacts
path: ${{ steps.releaseApk.outputs.apkfile }}