Example application and CI/CD pipeline showing how to run a React Native project on Semaphore 2.0. Uses React Native CLI Quickstart.
- Fork this repository and use it to create a project.
The CI pipeline will look like this:
To run just iOS CI, change pipeline file to run ios.yml
:
The CI pipeline will look like this (iOS):
To run just Android CI, change pipeline file to run android.yml
:
The CI pipeline will look like this (Android):
The example pipeline contains 4 blocks:
- Install dependencies
- Installs and caches all npm dependencies
- Run linter
- Lint the code using eslint with @react-native-community/eslint-config
- Run tests
- Build app
- Uses Fastlane as build automation tool (with a refference to Fastlane — Simple React Native iOS Releases and Fastlane — Simple React Native Android Releases)
$ npm install
$ npm start
$ npm run lint
$ npm test
$ npm run detox-ios-build
$ npm run detox-ios-test
$ npm run detox-android-build
$ npm run detox-android-test
If while runing your end to end tests on iOS you get this error #error Unsupported architecture
make sure that the detox configuration uses the ONLY_ACTIVE_ARCH=YES
flag as shown in the package.json file.
Copyright (c) 2019 Rendered Text
Distributed under the MIT License. See the file LICENSE.md.