Skip to content

Merge pull request #319 from LookUpGroup27/feat/lock-app-into-portrai… #130

Merge pull request #319 from LookUpGroup27/feat/lock-app-into-portrai…

Merge pull request #319 from LookUpGroup27/feat/lock-app-into-portrai… #130

Workflow file for this run

name: Build Android APK
on:
push:
branches:
- main
- M1
- feature/apk-for-m2
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup JDK
uses: actions/setup-java@v1
with:
distribution: "temurin"
java-version: "17"
- name: Set up Android SDK
uses: android-actions/setup-android@v3
with:
api-level: 34
build-tools: 34.0.0
- name: Grant execute permission for gradlew
run: |
chmod +x ./gradlew
- name: Decode secrets
env:
GOOGLE_SERVICES: ${{ secrets.GOOGLE_SERVICES }}
UPLOAD_KEYSTORE: ${{ secrets.UPLOAD_KEYSTORE }}
LOCAL_PROPERTIES: ${{ secrets.LOCAL_PROPERTIES }}
RELEASE_STORE_PASSWORD: ${{ secrets.RELEASE_STORE_PASSWORD }}
RELEASE_KEY_PASSWORD: ${{ secrets.RELEASE_KEY_PASSWORD }}
RELEASE_KEY_ALIAS: ${{ secrets.RELEASE_KEY_ALIAS }}
MAPS_API_KEY: ${{ secrets.MAPS_API_KEY }}
run: |
echo "$GOOGLE_SERVICES" | base64 --decode > ./app/google-services.json
echo "$UPLOAD_KEYSTORE" | base64 --decode > ./upload-keystore.jks
echo "$LOCAL_PROPERTIES" | base64 --decode > ./local.properties
- name: Build APK
run: ./gradlew assembleRelease
- name: Upload APK
uses: actions/upload-artifact@v3
with:
name: app-release-apk
path: app/build/outputs/apk/release/app-release.apk