Skip to content

where????

where???? #9

Workflow file for this run

name: Android CI
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
env:
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
KEY_ALIAS: ${{ secrets.KEY_ALIAS }}
KEY_PASSWORD: ${{ secrets.KEY_PASSWORD }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'adopt'
java-version: '17'
- name: Setup Android SDK
uses: android-actions/[email protected]
- name: keystore
run: echo "${{ secrets.KEYSTORE_FILE }}" | base64 --decode > keystore.jks
- name: Build
run: ./gradlew assembleRelease --stacktrace
- name: List build output files
run: ls -R .
- name: Sign the APK
run: |
jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 \
-keystore keystore.jks \
-storepass $KEYSTORE_PASSWORD \
-keypass $KEY_PASSWORD \
app/build/outputs/apk/release/app-release-unsigned.apk \
$KEY_ALIAS
- name: Align APK with zipalign
run: |
$ANDROID_HOME/build-tools/$(ls $ANDROID_HOME/build-tools | tail -n 1)/zipalign -v -p 4 \
app/build/outputs/apk/release/app-release-unsigned.apk \
app/build/outputs/apk/release/app-release.apk
- name: Upload signed APK
uses: actions/upload-artifact@v3
with:
name: app-release.apk
path: app/build/outputs/apk/release/app-release.apk