-
-
Notifications
You must be signed in to change notification settings - Fork 413
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
BREAKING CHANGE: only Android API level >=21 (Android 5) and iOS >= 11 are supported�� apart from green CI, this fixed at least one bug as well
- Loading branch information
Showing
49 changed files
with
3,319 additions
and
2,905 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,24 @@ | ||
version: 2.1 | ||
|
||
orbs: | ||
rn: react-native-community/[email protected] | ||
rn: react-native-community/[email protected] | ||
android: circleci/[email protected] | ||
|
||
# - rn/yarn_install | ||
# 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 | ||
# that is why we use yarn install --frozen-lockfile but that is SLOW! help us to fix this! | ||
|
||
jobs: | ||
checkout_code: | ||
analyse_js: | ||
executor: | ||
name: rn/linux_js | ||
node_version: '12.10.0' | ||
node_version: '14.17.0' | ||
steps: | ||
- checkout | ||
- persist_to_workspace: | ||
paths: . | ||
root: . | ||
analyse_js: | ||
executor: rn/linux_js | ||
steps: | ||
- attach_workspace: | ||
at: . | ||
# - rn/yarn_install | ||
# 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 | ||
- run: | ||
command: yarn install --frozen-lockfile --ignore-engines | ||
command: yarn install --frozen-lockfile | ||
name: yarn install | ||
- run: | ||
command: yarn lint | ||
|
@@ -36,84 +29,96 @@ jobs: | |
- run: | ||
command: yarn test | ||
name: Jest | ||
|
||
e2e_release_ios: | ||
executor: | ||
name: rn/macos | ||
xcode_version: '11.4.0' | ||
xcode_version: '13.1.0' | ||
steps: | ||
- attach_workspace: | ||
at: . | ||
- rn/setup_macos_executor: | ||
node_version: '12.10.0' | ||
- checkout | ||
- run: | ||
name: install applesimutils | ||
command: | | ||
HOMEBREW_NO_INSTALL_CLEANUP=1 HOMEBREW_NO_AUTO_UPDATE=1 brew tap wix/brew >/dev/null | ||
HOMEBREW_NO_INSTALL_CLEANUP=1 HOMEBREW_NO_AUTO_UPDATE=1 brew install applesimutils >/dev/null | ||
- rn/ios_simulator_start: | ||
device: 'iPhone 11' | ||
# - rn/yarn_install | ||
- run: | ||
command: yarn install --frozen-lockfile --ignore-engines | ||
command: yarn install --frozen-lockfile | ||
name: yarn install | ||
- rn/pod_install: | ||
pod_install_directory: 'example/ios' | ||
- run: | ||
command: curl https://raw.githubusercontent.com/facebook/react-native/6334ac35ac3cbc2c84b2d46d46ec118bf9bf714d/scripts/find-node.sh > node_modules/react-native/scripts/find-node.sh | ||
name: fix issue with nvm # will be fixed in RN 67 (https://github.com/react-native-community/upgrade-support/issues/138) | ||
- run: | ||
command: yarn detox:ios:build:release | ||
name: build for detox | ||
name: build app for e2e tests | ||
- run: | ||
command: yarn detox:ios:test:release | ||
name: test detox | ||
name: run e2e tests | ||
- store_artifacts: | ||
path: ./artifacts | ||
|
||
e2e_release_android: | ||
# we need to use mac to run emulator with acceleration | ||
# see https://support.circleci.com/hc/en-us/articles/360000028928-Testing-with-Android-emulator-on-CircleCI-2-0 | ||
executor: | ||
name: rn/macos | ||
xcode_version: '11.4.0' | ||
name: android/android-machine | ||
resource-class: large | ||
steps: | ||
- attach_workspace: | ||
at: . | ||
- rn/setup_macos_executor: | ||
node_version: '12.10.0' | ||
# - rn/yarn_install | ||
- checkout | ||
- run: | ||
command: yarn install --frozen-lockfile --ignore-engines | ||
name: change default node version | ||
command: | | ||
nvm install v15.11.0 | ||
nvm alias default v15.11.0 | ||
echo 'export PATH=/opt/circleci/.nvm/versions/node/v15.11.0/bin:$PATH' >> $BASH_ENV | ||
- android/create-avd: | ||
avd-name: TestingAVD | ||
system-image: system-images;android-29;default;x86 | ||
install: true | ||
- android/start-emulator: | ||
avd-name: TestingAVD | ||
no-window: true | ||
restore-gradle-cache-prefix: v1a | ||
post-emulator-launch-assemble-command: "pwd" | ||
- android/disable-animations | ||
- run: | ||
command: npm install --global yarn | ||
name: install yarn | ||
- run: | ||
command: yarn install --frozen-lockfile | ||
name: yarn install | ||
- rn/android_emulator_start: | ||
logcat_grep: 'com.reactcommunity.rndatetimepicker' | ||
- run: | ||
command: yarn detox:android:build:release | ||
name: build for detox | ||
name: build app for e2e tests | ||
- run: | ||
command: yarn detox:android:test:release | ||
name: test detox | ||
name: run e2e tests | ||
- store_artifacts: | ||
path: ./artifacts | ||
|
||
publish: | ||
executor: rn/linux_js | ||
executor: | ||
name: rn/linux_js | ||
node_version: '14.17.0' | ||
steps: | ||
- attach_workspace: | ||
at: . | ||
- checkout | ||
# - rn/yarn_install | ||
# 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 | ||
- run: | ||
command: yarn install --frozen-lockfile --ignore-engines | ||
command: yarn install --frozen-lockfile | ||
name: yarn install | ||
- run: | ||
command: npx semantic-release | ||
name: Publish to NPM | ||
|
||
|
||
workflows: | ||
test: | ||
jobs: | ||
- checkout_code | ||
- analyse_js: | ||
requires: | ||
- checkout_code | ||
- e2e_release_ios: | ||
requires: | ||
- analyse_js | ||
- e2e_release_android: | ||
requires: | ||
- analyse_js | ||
- analyse_js | ||
- e2e_release_ios | ||
- e2e_release_android | ||
- publish: | ||
requires: | ||
- e2e_release_android | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.