-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
62 lines (61 loc) · 2.65 KB
/
reanimated-compatibility-check-nightly.yml
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
name: React Native compatibility check [Nightly]
on:
pull_request:
paths:
- .github/workflows/reanimated-compatibility-check-nightly.yml
schedule:
- cron: '37 19 * * *'
workflow_dispatch:
jobs:
build_ios:
if: github.repository == 'software-mansion/react-native-reanimated'
runs-on: ${{matrix.platform == 'iOS' && 'macos-14' || 'ubuntu-latest'}}
strategy:
matrix:
platform: ['iOS', 'Android']
# TODO: Fetch compatibility in docs and here from common sources.
# Update it when dropping support for RN versions.
react-native:
[
{ version: '0.72', architecture: 'Paper' },
{ version: '0.73', architecture: 'Paper' },
{ version: '0.74', architecture: 'Paper' },
{ version: '0.75', architecture: 'Paper' },
{ version: '0.75', architecture: 'Fabric' },
]
fail-fast: false
env:
APP_NAME: app
RCT_NEW_ARCH_ENABLED: ${{ matrix.react-native.architecture == 'Fabric' && '1' || '0' }}
concurrency:
group: react-native-nightly-reanimated-build-check-${{ matrix.react-native.version}}-${{matrix.platform}}-${{matrix.react-native.architecture}}-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Set up JDK 18
if: ${{ matrix.platform == 'Android' }}
uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '18'
- name: Create app
run: |
npx react-native init ${{env.APP_NAME}} --version ${{ matrix.react-native.version }} --skip-install --pm yarn --skip-install --install-pods false --skip-git-init
- name: Install Reanimated
working-directory: ${{ env.APP_NAME }}
run: yarn add react-native-reanimated@https://github.com/software-mansion/react-native-reanimated.git#commit=${{ github.sha }}
- name: Install Pods
if: ${{ matrix.platform == 'iOS' }}
working-directory: ${{ env.APP_NAME }}/ios
run: bundle install && bundle exec pod install
- name: Setup Fabric (Android)
if: ${{ matrix.platform == 'Android' && matrix.react-native.architecture == 'Fabric' }}
working-directory: ${{ env.APP_NAME }}/android
run: sed -i 's/newArchEnabled=false/newArchEnabled=true/' gradle.properties
- name: Build app (iOS)
if: ${{ matrix.platform == 'iOS' }}
working-directory: ${{ env.APP_NAME }}
run: yarn react-native run-ios --simulator='iPhone 14'
- name: Build app (Android)
if: ${{ matrix.platform == 'Android' }}
working-directory: ${{ env.APP_NAME }}/android
run: ./gradlew assembleDebug --console=plain