Skip to content

Merge pull request #21 from ArinNigam/user-frontend #54

Merge pull request #21 from ArinNigam/user-frontend

Merge pull request #21 from ArinNigam/user-frontend #54

name: Flutter Build Apk
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
defaults:
run:
working-directory: ./frontend
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
- uses: actions/setup-java@v4
with:
distribution: "oracle"
java-version: "17"
- uses: subosito/flutter-action@v2
with:
channel: "beta"
- name: Create .env file
run: touch .env
- name: Get dependencies
run: flutter pub get
- name: Format code
run: dart format .
- name: Build APK
run: flutter build apk
- name: Upload APK artifact
uses: actions/upload-artifact@v2
with:
name: release-apk
path: frontend/build/app/outputs/apk/release/app-release.apk