11version : 2.1
22
33orbs :
4- rn : react-native-community/react-native@4.4.2
4+ rn : react-native-community/react-native@5.6.2
5+ android : circleci/android@1.0.3
56
67# - rn/yarn_install
78# fails with Error untarring cache: Error extracting tarball /var/folders/bq/mjrgbpkx5h1g_b22fpv0tlzc0000gn/T/cache376822577 : tmp/yarn/: Cannot extract through symlink tmp/yarn tmp/yarn/v6/: Cannot extract through symlink tmp/yarn/v6 tmp/yarn/v6/.tmp/: Cannot extract through symlink tmp/yarn/v6/.tmp tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/code-frame/: Cannot extract: exit status 1
89# that is why we use yarn install --frozen-lockfile but that is SLOW! help us to fix this!
910
1011jobs :
11- checkout_code :
12+ analyse_js :
1213 executor :
1314 name : rn/linux_js
14- node_version : ' 12.10 .0'
15+ node_version : ' 14.17 .0'
1516 steps :
1617 - checkout
17- - persist_to_workspace :
18- paths : .
19- root : .
20- analyse_js :
21- executor : rn/linux_js
22- steps :
23- - attach_workspace :
24- at : .
2518 # - rn/yarn_install
2619 # fails with Error untarring cache: Error extracting tarball /var/folders/bq/mjrgbpkx5h1g_b22fpv0tlzc0000gn/T/cache376822577 : tmp/yarn/: Cannot extract through symlink tmp/yarn tmp/yarn/v6/: Cannot extract through symlink tmp/yarn/v6 tmp/yarn/v6/.tmp/: Cannot extract through symlink tmp/yarn/v6/.tmp tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/code-frame/: Cannot extract: exit status 1
2720 - run :
28- command : yarn install --frozen-lockfile --ignore-engines
21+ command : yarn install --frozen-lockfile
2922 name : yarn install
3023 - run :
3124 command : yarn lint
@@ -36,84 +29,96 @@ jobs:
3629 - run :
3730 command : yarn test
3831 name : Jest
32+
3933 e2e_release_ios :
4034 executor :
4135 name : rn/macos
42- xcode_version : ' 11.4 .0'
36+ xcode_version : ' 13.1 .0'
4337 steps :
44- - attach_workspace :
45- at : .
46- - rn/setup_macos_executor :
47- node_version : ' 12.10.0'
38+ - checkout
39+ - run :
40+ name : install applesimutils
41+ command : |
42+ HOMEBREW_NO_INSTALL_CLEANUP=1 HOMEBREW_NO_AUTO_UPDATE=1 brew tap wix/brew >/dev/null
43+ HOMEBREW_NO_INSTALL_CLEANUP=1 HOMEBREW_NO_AUTO_UPDATE=1 brew install applesimutils >/dev/null
4844 - rn/ios_simulator_start :
4945 device : ' iPhone 11'
5046 # - rn/yarn_install
5147 - run :
52- command : yarn install --frozen-lockfile --ignore-engines
48+ command : yarn install --frozen-lockfile
5349 name : yarn install
5450 - rn/pod_install :
5551 pod_install_directory : ' example/ios'
52+ - run :
53+ command : curl https://raw.githubusercontent.com/facebook/react-native/6334ac35ac3cbc2c84b2d46d46ec118bf9bf714d/scripts/find-node.sh > node_modules/react-native/scripts/find-node.sh
54+ name : fix issue with nvm # will be fixed in RN 67 (https://github.com/react-native-community/upgrade-support/issues/138)
5655 - run :
5756 command : yarn detox:ios:build:release
58- name : build for detox
57+ name : build app for e2e tests
5958 - run :
6059 command : yarn detox:ios:test:release
61- name : test detox
60+ name : run e2e tests
6261 - store_artifacts :
6362 path : ./artifacts
63+
6464 e2e_release_android :
65- # we need to use mac to run emulator with acceleration
66- # see https://support.circleci.com/hc/en-us/articles/360000028928-Testing-with-Android-emulator-on-CircleCI-2-0
6765 executor :
68- name : rn/macos
69- xcode_version : ' 11.4.0 '
66+ name : android/android-machine
67+ resource-class : large
7068 steps :
71- - attach_workspace :
72- at : .
73- - rn/setup_macos_executor :
74- node_version : ' 12.10.0'
75- # - rn/yarn_install
69+ - checkout
7670 - run :
77- command : yarn install --frozen-lockfile --ignore-engines
71+ name : change default node version
72+ command : |
73+ nvm install v15.11.0
74+ nvm alias default v15.11.0
75+ echo 'export PATH=/opt/circleci/.nvm/versions/node/v15.11.0/bin:$PATH' >> $BASH_ENV
76+ - android/create-avd :
77+ avd-name : TestingAVD
78+ system-image : system-images;android-29;default;x86
79+ install : true
80+ - android/start-emulator :
81+ avd-name : TestingAVD
82+ no-window : true
83+ restore-gradle-cache-prefix : v1a
84+ post-emulator-launch-assemble-command : " pwd"
85+ - android/disable-animations
86+ - run :
87+ command : npm install --global yarn
88+ name : install yarn
89+ - run :
90+ command : yarn install --frozen-lockfile
7891 name : yarn install
79- - rn/android_emulator_start :
80- logcat_grep : ' com.reactcommunity.rndatetimepicker'
8192 - run :
8293 command : yarn detox:android:build:release
83- name : build for detox
94+ name : build app for e2e tests
8495 - run :
8596 command : yarn detox:android:test:release
86- name : test detox
97+ name : run e2e tests
8798 - store_artifacts :
8899 path : ./artifacts
100+
89101 publish :
90- executor : rn/linux_js
102+ executor :
103+ name : rn/linux_js
104+ node_version : ' 14.17.0'
91105 steps :
92- - attach_workspace :
93- at : .
106+ - checkout
94107 # - rn/yarn_install
95108 # fails with Error untarring cache: Error extracting tarball /var/folders/bq/mjrgbpkx5h1g_b22fpv0tlzc0000gn/T/cache376822577 : tmp/yarn/: Cannot extract through symlink tmp/yarn tmp/yarn/v6/: Cannot extract through symlink tmp/yarn/v6 tmp/yarn/v6/.tmp/: Cannot extract through symlink tmp/yarn/v6/.tmp tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/: Cannot extract through symlink tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel tmp/yarn/v6/npm-@babel-code-frame-7.8.3-33e25903d7481181534e12ec0a25f16b6fcf419e-integrity/node_modules/@babel/code-frame/: Cannot extract: exit status 1
96109 - run :
97- command : yarn install --frozen-lockfile --ignore-engines
110+ command : yarn install --frozen-lockfile
98111 name : yarn install
99112 - run :
100113 command : npx semantic-release
101114 name : Publish to NPM
102115
103-
104116workflows :
105117 test :
106118 jobs :
107- - checkout_code
108- - analyse_js :
109- requires :
110- - checkout_code
111- - e2e_release_ios :
112- requires :
113- - analyse_js
114- - e2e_release_android :
115- requires :
116- - analyse_js
119+ - analyse_js
120+ - e2e_release_ios
121+ - e2e_release_android
117122 - publish :
118123 requires :
119124 - e2e_release_android
0 commit comments