-
Notifications
You must be signed in to change notification settings - Fork 141
62 lines (55 loc) · 1.43 KB
/
build.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# src: https://gist.github.com/rodydavis/bde9a9a8c2fcdcf3474c0f50248f2e3a
name: Flutter Build
on:
pull_request:
branches:
- master
push:
branches:
- master
# Cancel jobs and just run the last one
concurrency:
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.run_number || github.ref }}
cancel-in-progress: true
defaults:
run:
working-directory: example/
jobs:
build_web:
name: Build Web
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: subosito/flutter-action@v1
with:
flutter-version: '3.0.0'
- run: flutter pub get
- run: flutter config --enable-web
- run: flutter build web
build_ios:
name: Build iOS
runs-on: macOS-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-java@v1
with:
java-version: '12.x'
- uses: subosito/flutter-action@v1
with:
flutter-version: '3.0.0'
- run: flutter pub get
- run: flutter clean
- run: flutter build ios --release --no-codesign
build_android:
name: Build Android
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions/setup-java@v1
with:
java-version: '12.x'
- uses: subosito/flutter-action@v1
with:
flutter-version: '3.0.0'
- run: flutter pub get
- run: flutter build appbundle