-
Notifications
You must be signed in to change notification settings - Fork 2
44 lines (36 loc) · 1 KB
/
dart.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: Dart
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v4
# Set up Java 17
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: "temurin" # This is an OpenJDK distribution
java-version: "17"
# Set up Flutter
- name: Set up Flutter
uses: subosito/flutter-action@v2
with:
channel: stable
flutter-version: 3.24.2
- run: flutter --version
- run: flutter pub get
# Build APK for debugging
- run: flutter build apk --debug --split-per-abi -t lib/main.dart
- run: flutter build appbundle
# Push the release
- name: Push to Releases
uses: ncipollo/release-action@v1
with:
artifacts: "build/app/outputs/apk/debug/*"
tag: v1.0.${{ github.run_number }}
token: ${{ secrets.TOKEN }}