Skip to content

Commit

Permalink
ci: add steps to bundle and build iOS and Android fixture apps (#78)
Browse files Browse the repository at this point in the history
  • Loading branch information
ElviraBurchik authored Jun 15, 2022
1 parent a9b6a97 commit 1576f1b
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 0 deletions.
74 changes: 74 additions & 0 deletions .github/workflows/react-native-performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,3 +73,77 @@ jobs:
run: |
yarn
yarn test --forceExit
metro-ios:
name: "Metro bundling for iOS"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
- run: |
yarn
yarn build
cd fixture
yarn
mkdir -p /tmp/artifacts
yarn react-native bundle --entry-file index.js --platform ios --bundle-output /tmp/artifacts/bundle.js --sourcemap-output /tmp/artifacts/output.map
metro-android:
name: "Metro bundling for Android"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
- run: |
cd fixture
yarn
cd android
mkdir -p /tmp/artifacts
./gradlew bundleDebugJsAndAssets
build-ios:
name: "Build iOS"
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
- name: ruby setup
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ env.RUBY_VERSION }}
bundler-cache: true
- run: |
bundle install
cd fixture
yarn
cd ios
bundle exec pod install
mkdir -p /tmp/artifacts
set -o pipefail && env NSUnbufferedIO=YES xcodebuild clean build -scheme ReactNativePerformanceFixture -workspace ReactNativePerformanceFixture.xcworkspace -destination 'platform=iOS Simulator,name=iPhone 11,OS=latest' | tee /tmp/artifacts/ios_build.log
- name: Archive iOS build artifacts
uses: actions/upload-artifact@v3
with:
name: ios-build-artifacts
path: /tmp/artifacts
build-android:
name: "Build Android"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
- name: ruby setup
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ env.RUBY_VERSION }}
bundler-cache: true
- run: |
bundle install
cd fixture
yarn
cd android
./gradlew assembleDebug
1 change: 1 addition & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ GEM

PLATFORMS
arm64-darwin-21
x86_64-darwin-19
x86_64-linux

DEPENDENCIES
Expand Down

0 comments on commit 1576f1b

Please sign in to comment.