-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathcodemagic.yaml
More file actions
68 lines (59 loc) · 1.81 KB
/
codemagic.yaml
File metadata and controls
68 lines (59 loc) · 1.81 KB
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
64
65
66
67
workflows:
release:
name: Build Android & iOS Release
max_build_duration: 60
environment:
flutter: 3.41.6
xcode: latest
cocoapods: default
vars:
MOOSE_GAME_SECRET: $MOOSE_GAME_SECRET
triggering:
events:
- push
branch_patterns:
- pattern: production
include: true
source: true
cache:
cache_paths:
- ~/.pub-cache
- ~/.gradle/caches
- ~/.gradle/wrapper
- ios/Pods
scripts:
- name: Get Flutter packages
script: flutter pub get
- name: Generate API client
script: |
cd lib/api_client
flutter pub get
flutter pub run build_runner build --delete-conflicting-outputs
cd ../..
- name: Install CocoaPods
script: |
cd ios
pod install --repo-update
cd ..
- name: Set build number
script: |
flutter pub run flutter_version increment-build-number --build-number $BUILD_NUMBER
- name: Build Android AppBundle (release)
script: flutter build appbundle --release --build-number=$BUILD_NUMBER
- name: Build Android APK (release)
script: flutter build apk --release --build-number=$BUILD_NUMBER
- name: Build iOS IPA
script: flutter build ipa --release --no-codesign --build-number=$BUILD_NUMBER
artifacts:
- build/app/outputs/bundle/release/*.aab
- build/app/outputs/flutter-apk/*.apk
- build/ios/ipa/*.ipa
- flutter_drive.log
publishing:
google_play:
credentials: $GCLOUD_SERVICE_ACCOUNT_CREDENTIALS
track: production
app_store_connect:
api_key: $APP_STORE_CONNECT_PRIVATE_KEY
key_id: $APP_STORE_CONNECT_KEY_IDENTIFIER
issuer_id: $APP_STORE_CONNECT_ISSUER_ID