Skip to content
name: Upload React Native Android & iOS Quick Start build on appeitize
on:
push:
branches:
- main
paths:
- 'react-native/rn-bare-quick-start/**'
defaults:
run:
working-directory: ./react-native/rn-bare-quick-start/
jobs:
build-and-upload:
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set Up JDK
uses: actions/setup-java@v3
with:
distribution: "zulu"
java-version: "17"
cache: "gradle"
- name: Install Dependencies
run: npm install
- name: Bundle Android build
run : |
npx mkdirp android/app/src/main/assets/
npx react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res
- name: Build APK
run: |
cd android
./gradlew assembleDebug
- name: Pod Install
run: |
cd ios
pod install
- name: Bundle iOS build
run: npx react-native bundle --platform ios --dev false --entry-file index.js --bundle-output ios/main.jsbundle --assets-dest ios
- name: Build iOS simulator build
run: |
cd ios
xcodebuild -workspace web3authrnexample.xcworkspace -scheme web3authrnexample -sdk iphonesimulator -derivedDataPath build
- name: Compress iOS build
run: |
cd ios
tar -czf ios_build.tar.gz build/Build/Products/Debug-iphonesimulator
- name: Upload Android build to Appeitize
uses: appetizeio/github-action-appetize@v1.0.1
with:
apiToken: ${{ secrets.APPETIZE_SECRET_KEY }}
publicKey: ${{ secrets.RN_ANDROID_QUICK_START_PUBLIC_KEY }}
appFile: ./react-native/rn-bare-quick-start/android/app/build/outputs/apk/debug/app-debug.apk
platform: "android"
- name: Upload iOS build to Appeitize
uses: appetizeio/github-action-appetize@v1.0.1
with:
apiToken: ${{ secrets.APPETIZE_SECRET_KEY }}
publicKey: ${{ secrets.RN_IOS_QUICK_START_PUBLIC_KEY }}
appFile: ./react-native/rn-bare-quick-start/ios/ios_build.tar.gz
platform: "ios"