Skip to content

add CI env

add CI env #66

Workflow file for this run

name: '[CI] React Native'
on:
push:
branches:
- main
- vr/cache-dependencies
pull_request:
branches:
- main
workflow_dispatch:
env:
CI: true
jobs:
ci:
runs-on: flyci-macos-14-m2
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'yarn'
- uses: ruby/setup-ruby@v1
with:
ruby-version: 3.3
bundler-cache: true
- name: Cache node_modules
id: modules-cache
uses: actions/cache@v4
with:
path: ./node_modules
key: ${{ runner.os }}-modules-${{ hashFiles('yarn.lock') }}
- name: Install node_modules
if: steps.modules-cache.outputs.cache-hit != 'true'
shell: bash
run: |
set -euxo pipefail
yarn install --frozen-lockfile
- name: Run eslint
run: |
set -euxo pipefail
yarn lint
- name: Run tests
run: |
set -euxo pipefail
yarn test
- name: Cache Pods
uses: actions/cache@v4
id: pods-cache
with:
path: ./ios/Pods
key: ${{ runner.os }}-pods-${{ hashFiles('ios/Podfile.lock') }}
- name: Install pods
if: steps.pods-cache.outputs.cache-hit != 'true'
working-directory: ios
run: |
set -euxo pipefail
bundle exec pod install
- name: LS ios
working-directory: ios
run: ls -lh
- name: Build iOS
working-directory: ios
run: |
set -euxo pipefail
yarn build-ios
# - name: Build Android
# working-directory: ios
# run: |
# set -euxo pipefail
# yarn build-android