-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (54 loc) · 2.1 KB
/
flutter.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
62
63
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Flutter build appbundle
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '11'
- uses: subosito/flutter-action@v2
with:
flutter-version: '3.16.3'
- run: flutter pub get
- name: set local properties
run: |
echo "" >> ./android/local.properties
echo flutter.minSdkVersion=21 >> ./android/local.properties
echo flutter.targetSdkVersion=30 >> ./android/local.properties
echo flutter.compileSdkVersion=30 >> ./android/local.properties
- name: test
env:
TEST_INSTANCE_URL: ${{ secrets.TEST_INSTANCE_URL }}
# run: |
# flutter packages pub run build_runner build
# flutter drive \
# --dart-define=ELN_PASSWORD=@complat \
# --dart-define=ELN_URL=$TEST_INSTANCE_URL
# --driver=test_driver/integration_test.dart \
# --target=integration_test/app_test.dart
- name: set key properties
run: |
echo keyPassword=\${{ secrets.KEY_PASSWORD }} > ./android/key.properties
echo storePassword=\${{ secrets.STORE_PASSWORD }} >> ./android/key.properties
echo keyAlias=\${{ secrets.KEY_ALIAS }} >> ./android/key.properties
echo storeFile=upload-keystore.jks >> ./android/key.properties
echo "${{ secrets.KEYS_JKS }}" | base64 --decode > ./android/app/upload-keystore.jks
# - run: flutter build apk
- run: flutter build appbundle
- name: Upload artefact
uses: actions/upload-artifact@v3
with:
name: appbundle
path: build/app/outputs/bundle/release/app-release.aab