forked from BasedHardware/omi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
codemagic.yaml
134 lines (131 loc) · 4.86 KB
/
codemagic.yaml
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
workflows:
# android-workflow:
# name: Android Workflow
# instance_type: mac_mini_m1
# max_build_duration: 120
# working_directory: app
# environment:
# android_signing:
# - keystore_reference
# groups:
# - google_play # <-- (Includes GCLOUD_SERVICE_ACCOUNT_CREDENTIALS)
# vars:
# PACKAGE_NAME: "com.friend.ios"
# GOOGLE_PLAY_TRACK: "alpha"
# flutter: stable
# scripts:
# - name: Set up local.properties
# script: |
# echo "flutter.sdk=$HOME/programs/flutter" > "$CM_BUILD_DIR/android/local.properties"
# - name: Get Flutter packages
# script: |
# flutter packages pub get
# - name: Flutter analyze
# script: |
# flutter analyze
# - name: Flutter unit tests
# script: |
# flutter test
# ignore_failure: true
# - name: Build AAB with Flutter
# script: |
# BUILD_NUMBER=$(($(google-play get-latest-build-number --package-name "$PACKAGE_NAME" --tracks="$GOOGLE_PLAY_TRACK") + 1))
# flutter build appbundle --release \
# --build-name=1.0.$BUILD_NUMBER \
# --build-number=$BUILD_NUMBER
# artifacts:
# - build/**/outputs/**/*.aab
# - build/**/outputs/**/mapping.txt
# - flutter_drive.log
# publishing:
# email:
# recipients:
# notify:
# success: true
# failure: false
# google_play:
# credentials: $GCLOUD_SERVICE_ACCOUNT_CREDENTIALS
# track: $GOOGLE_PLAY_TRACK
# submit_as_draft: true
ios-workflow:
name: iOS Workflow
instance_type: mac_mini_m1
max_build_duration: 120
working_directory: app
integrations:
app_store_connect: codemagic
environment:
ios_signing:
distribution_type: app_store
bundle_identifier: com.friend-app-with-wearable.ios12
vars:
APP_ID: 6502156163
flutter: stable
xcode: latest
cocoapods: default
groups:
- appstore_credentials
- firebase_credentials
scripts:
- name: Set up code signing settings on Xcode project
script: |
xcode-project use-profiles
- name: Get Flutter packages
script: |
flutter packages pub get
- name: Install pods
script: |
find . -name "Podfile" -execdir pod install \;
- name: Flutter analyze
script: |
flutter analyze
# - name: Flutter unit tests
# script: |
# flutter test
ignore_failure: true
- name: Load Firebase configuration
script: |
#!/usr/bin/env sh
set -e # exit on first failed command
echo $ANDROID_FIREBASE_SECRET > $CM_BUILD_DIR/android/app/google-services.json
echo $IOS_FIREBASE_SECRET > $CM_BUILD_DIR/ios/Runner/GoogleService-Info.plist
- name: Flutter build ipa and automatic versioning
script: |
# See the following link about getting the latest App Store or TestFlight version - https://docs.codemagic.io/knowledge-codemagic/build-versioning/#app-store-or-testflight-latest-build-number
flutter build ipa --release \
--build-name=1.0.20 \
--build-number=$(($(app-store-connect get-latest-testflight-build-number "$APP_ID") + 1)) \
--export-options-plist=/Users/builder/export_options.plist
artifacts:
- build/ios/ipa/*.ipa
- /tmp/xcodebuild_logs/*.log
- flutter_drive.log
publishing:
# See the following link for details about email publishing - https://docs.codemagic.io/publishing-yaml/distribution/#email
email:
recipients:
notify:
success: true # To receive a notification when a build succeeds
failure: false # To not receive a notification when a build fails
slack:
# See the following link about how to connect your Slack account - https://docs.codemagic.io/publishing-yaml/distribution/#slack
channel: "#builds"
notify_on_build_start: true # To receive a notification when a build starts
notify:
success: true # To receive a notification when a build succeeds
failure: false # To not receive a notification when a build fails
app_store_connect:
auth: integration
# Configuration related to TestFlight (optional)
# Note: This action is performed during post-processing.
submit_to_testflight: true
beta_groups: # Specify the names of beta tester groups that will get access to the build once it has passed beta review.
- Discord Folks
- Internal 2
# Configuration related to App Store (optional)
# Note: This action is performed during post-processing.
submit_to_app_store: false