-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcodemagic.yaml
80 lines (79 loc) · 2.19 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
workflows:
react-native-android:
name: React Native Android
working_directory: react-native
max_build_duration: 120
instance_type: mac_mini
environment:
groups:
- keystore_credentials
vars:
PACKAGE_NAME: "no.itverket.itdagene.reactnative"
scripts:
- name: Set up keystore
script: |
echo $CM_KEYSTORE | base64 --decode > $CM_KEYSTORE_PATH
- name: Install npm dependencies
script: |
npm install
- name: Install Expo CLI and eject
script: |
npm install -g expo-cli
expo eject
- name: Set up app/build.gradle
script: |
mv ./support-files/build.gradle android/app
- name: Set Android SDK location
script: |
echo "sdk.dir=$ANDROID_SDK_ROOT" > "$CM_BUILD_DIR/local.properties"
- name: Build Android release
script: |
cd android && ./gradlew assembleRelease
artifacts:
- android/app/build/outputs/**/*.apk
publishing:
email:
recipients:
- abe@itverket.no
- bv@itverket.no
notify:
success: true
failure: false
flutter-android:
name: Flutter Android
working_directory: ./
max_build_duration: 120
environment:
flutter: stable
xcode: latest
cocoapods: default
scripts:
- name: Set up debug keystore
script: |
rm -f ~/.android/debug.keystore
keytool -genkeypair \
-alias androiddebugkey \
-keypass android \
-keystore ~/.android/debug.keystore \
-storepass android \
-dname 'CN=Android Debug,O=Android,C=US' \
-keyalg 'RSA' \
-keysize 2048 \
-validity 10000
- name: Get Flutter packages
script: |
flutter packages pub get
- name: Build APK with Flutter
script: |
flutter build apk --release
artifacts:
- build/**/outputs/apk/**/*.apk
publishing:
email:
recipients:
- abe@itverket.no
- bv@itverket.no
- andresaiteppeland@gmail.com
notify:
success: true
failure: false