Skip to content

chore(deps): bump @opentelemetry/instrumentation and @azure/opentelemetry-instrumentation-azure-sdk in /package #282

chore(deps): bump @opentelemetry/instrumentation and @azure/opentelemetry-instrumentation-azure-sdk in /package

chore(deps): bump @opentelemetry/instrumentation and @azure/opentelemetry-instrumentation-azure-sdk in /package #282

name: ReactNativeSlider-CI
on:
push:
branches:
- 'main'
- 'release/**'
pull_request:
types: [opened, reopened, synchronize]
jobs:
install:
name: Install dependencies
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Cache node modules
id: cache-package-npm
uses: actions/[email protected]
env:
cache-name: cached-ci-npm-deps
with:
path: ./package/node_modules
key: ${{ hashFiles('./package/package.json') }}
- name: Install required dependencies on cache miss (npm)
if: steps.cache-package-npm.outputs.cache-hit != 'true'
run: |
npm install
verify-package-sources:
name: Lint the sources
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Pull npm dependencies
uses: actions/[email protected]
with:
path: ./package/node_modules
key: ${{ hashFiles('./package/package.json') }}
- name: Run ESLint on the sources
run: cd package && npx eslint src
- name: Run TypeScript on the sources
run: cd package && npx tsc --noEmit
test:
name: Run the unit tests
runs-on: ubuntu-latest
needs: install
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Pull npm dependencies
uses: actions/[email protected]
with:
path: ./package/node_modules
key: ${{ hashFiles('./package/package.json') }}
- name: Run unit tests
run: cd package && npx jest src
verify-example-sources:
name: Verify example app sources
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install dependencies
run: npm install
- name: Run ESLint on the sources
run: cd example && npx eslint .
- name: Run TypeScript on the sources
run: cd example && npx tsc --noEmit
build-android-app:
name: Build example app Android
runs-on: ubuntu-latest
needs: [verify-example-sources]
steps:
- uses: actions/checkout@v3
- name: Pull the npm dependencies
run: npm install
- uses: actions/setup-java@v3
with:
distribution: 'zulu'
java-version: '11'
- name: Build the Android OS app
run: cd example/android && ./gradlew assembleDebug
build-iOS-app:
name: Build example app iOS
runs-on: macos-latest
needs: [verify-example-sources]
steps:
- uses: actions/checkout@v3
- name: Cache node modules
id: cache-npm
uses: actions/cache@v3
env:
cache-name: cached-ios-npm-deps
with:
path: example/node_modules
key: ${{ hashFiles('./example/package-lock.json') }}-${{ hashFiles('./package/package-lock.json') }}
- name: Install required dependencies on cache miss (npm)
if: steps.cache-npm.outputs.cache-hit != 'true'
run: |
npm install
- name: Cache Pods
id: cache-pods
uses: actions/cache@v3
env:
cache-name: cached-ios-pods-deps
with:
path: example/ios/Pods
key: ${{ hashFiles('./example/ios/Podfile.lock') }}
- name: Install required dependencies on cache miss (Pods)
if: steps.cache-pods.outputs.cache-hit != 'true'
run: |
cd example/ios && pod install
- name: Reinstall Pods only if using cached ones
if: steps.cache-pods.outputs.cache-hit == 'true'
run: cd example/ios && pod install
- name: Use the current package sources in build
run: cd example && npm run refresh-package
- name: Build iOS
run: |
device_name='iPhone 13'
device=$(xcrun simctl list devices "${device_name}" available | grep "${device_name} (")
re='\(([-0-9A-Fa-f]+)\)'
[[ $device =~ $re ]] || exit 1
xcodebuild -workspace example.xcworkspace -scheme example -destination "platform=iOS Simulator,id=${BASH_REMATCH[1]}" CODE_SIGNING_ALLOWED=NO COMPILER_INDEX_STORE_ENABLE=NO build
working-directory: example/ios
build-iOS-new-arch-app:
name: Build example app iOS (Fabric)
runs-on: macos-latest
needs: [build-iOS-app]
steps:
- uses: actions/checkout@v3
- name: Cache node modules
id: cache-npm
uses: actions/cache@v3
env:
cache-name: cached-ios-npm-deps
with:
path: example/node_modules
key: new-arch-${{ hashFiles('./example/package-lock.json') }}-${{ hashFiles('./package/package-lock.json') }}
- name: Install required dependencies on cache miss (npm)
if: steps.cache-npm.outputs.cache-hit != 'true'
run: |
npm install
- name: Cache Pods
id: cache-pods
uses: actions/cache@v3
env:
cache-name: cached-ios-pods-deps
with:
path: example/ios/Pods
key: new-arch-${{ hashFiles('./example/ios/Podfile.lock') }}
- name: Install required dependencies on cache miss (Pods)
if: steps.cache-pods.outputs.cache-hit != 'true'
run: |
cd example/ios && RCT_NEW_ARCH_ENABLED=1 pod install
- name: Reinstall Pods only if using cached ones
if: steps.cache-pods.outputs.cache-hit == 'true'
run: cd example/ios && RCT_NEW_ARCH_ENABLED=1 pod install
- name: Use the current package sources in build
run: cd example && npm run refresh-package
- name: Build iOS - Fabric
run: |
device_name='iPhone 13'
device=$(xcrun simctl list devices "${device_name}" available | grep "${device_name} (")
re='\(([-0-9A-Fa-f]+)\)'
[[ $device =~ $re ]] || exit 1
xcodebuild -workspace example.xcworkspace -scheme example -destination "platform=iOS Simulator,id=${BASH_REMATCH[1]}" CODE_SIGNING_ALLOWED=NO COMPILER_INDEX_STORE_ENABLE=NO build
working-directory: example/ios
build-Windows-app:
name: Build example app Windows
runs-on: windows-latest
needs: [verify-example-sources]
steps:
- name: Ensure the cross-platform Git on Windows
run: git config --global core.autocrlf false
- name: Checkout repository
uses: actions/checkout@v3
- name: Install dependencies
run: npm install
- name: Build the Windows OS app
run: cd example; npx react-native run-windows --arch x64 --no-launch --no-deploy --logging