Add signing config
This commit is contained in:
parent
d404f93e88
commit
a724630ced
3 changed files with 11 additions and 43 deletions
|
@ -1,42 +0,0 @@
|
|||
name: Android Signed Build and Release
|
||||
|
||||
on:
|
||||
push:
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: https://source.mapcomplete.org/actions/checkout@v4
|
||||
-
|
||||
uses: https://source.mapcomplete.org/actions/setup-android@v3.2.2
|
||||
|
||||
- name: Decode keystore
|
||||
run: |
|
||||
echo "${{ secrets.KEYSTORE_BASE64 }}" | base64 -d > my-release-key.jks
|
||||
|
||||
- name: Set up gradle properties
|
||||
run: |
|
||||
mkdir -p ~/.gradle
|
||||
echo "storeFile=my-release-key.jks" >> ~/.gradle/gradle.properties
|
||||
echo "storePassword=${{ secrets.KEYSTORE_PASSWORD }}" >> ~/.gradle/gradle.properties
|
||||
echo "keyAlias=${{ secrets.KEY_ALIAS }}" >> ~/.gradle/gradle.properties
|
||||
echo "keyPassword=${{ secrets.KEY_PASSWORD }}" >> ~/.gradle/gradle.properties
|
||||
|
||||
- name: Grant execute permission to gradlew
|
||||
run: chmod +x ./gradlew
|
||||
|
||||
- name: Build signed APK
|
||||
run: |
|
||||
export ANDROID_SDK_HOME=/home/runner/.android/sdk/
|
||||
export PATH=$ANDROID_SDK_HOME/tools:$ANDROID_SDK_HOME/platform-tools:$ANDROID_SDK_HOME/:$ANDROID_SDK_HOME/cmdline-tools/latest/tools/bin:$PATH
|
||||
./gradlew assembleRelease
|
||||
|
||||
- name: Upload APK to Release
|
||||
uses: https://code.forgejo.org/actions/forgejo-release@v2
|
||||
with:
|
||||
files: app/build/outputs/apk/release/*.apk
|
||||
env:
|
||||
FORGEJO_TOKEN: ${{ secrets.FORGEJO_TOKEN }}
|
Loading…
Add table
Add a link
Reference in a new issue