Skip to content

Commit

Permalink
Some modification
Browse files Browse the repository at this point in the history
  • Loading branch information
tuhinpal committed Jan 27, 2024
1 parent 389ed52 commit 22f452c
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Android Flutter Build then Release

on:
release:
types: [created]

jobs:
build:
name: Build Android
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: '3.10.5' # Your current version of flutter
channel: 'stable'
cache: true
cache-key: 'flutter-:os:-:channel:-:version:-:arch:-:hash:'
cache-path: '${{ runner.tool_cache }}/flutter/:channel:-:version:-:arch:'
architecture: x64

- name: Get dependencies
run: flutter pub get

- name: Build APK
run: flutter build apk

- name: Upload APK to Release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./build/app/outputs/flutter-apk/app-release.apk
asset_name: app-release.apk
asset_content_type: application/vnd.android.package-archive

0 comments on commit 22f452c

Please sign in to comment.