Skip to content

Commit

Permalink
Merge pull request #191 from PlayerData/update-expo
Browse files Browse the repository at this point in the history
feat(deps): Upgrade to Expo 50
  • Loading branch information
ball-hayden authored Jan 31, 2024
2 parents 2920b96 + fdd7ea4 commit d51aabc
Show file tree
Hide file tree
Showing 9 changed files with 12,442 additions and 10,642 deletions.
21 changes: 18 additions & 3 deletions .github/workflows/build_and_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,34 +32,49 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4

- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '18'

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20

- name: Making sure the android example app builds
run: |
npm install
cd example
npx expo prebuild
npm install
npx expo prebuild --platform android
cd android
./gradlew build
ios-example:
name: iOS example app
runs-on: macos-latest
runs-on: macos-14
needs: build
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20

- name: Making sure the ios example app builds
run: |
npm install
cd example
npx expo prebuild
npm install
npx expo prebuild --platform ios
cd ios
xcodebuild build -workspace reactnativemcumanagerexample.xcworkspace -scheme reactnativemcumanagerexample CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO
Expand Down
17 changes: 6 additions & 11 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,13 @@ apply plugin: 'maven-publish'
group = 'uk.co.playerdata.reactnativemcumanager'
version = '0.1.0'

def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
if (expoModulesCorePlugin.exists()) {
apply from: expoModulesCorePlugin
applyKotlinExpoModulesCorePlugin()
// Remove this check, but keep the contents after SDK49 support is dropped
if (safeExtGet("expoProvidesDefaultConfig", false)) {
useExpoPublishing()
useCoreDependencies()
buildscript {
def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
if (expoModulesCorePlugin.exists()) {
apply from: expoModulesCorePlugin
applyKotlinExpoModulesCorePlugin()
}
}

buildscript {
// Simple helper that allows the root project to override versions declared by this library.
ext.safeExtGet = { prop, fallback ->
rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
Expand Down Expand Up @@ -73,7 +68,7 @@ android {
namespace "uk.co.playerdata.reactnativemcumanager"
defaultConfig {
minSdkVersion safeExtGet("minSdkVersion", 21)
targetSdkVersion safeExtGet("targetSdkVersion", 33)
targetSdkVersion safeExtGet("targetSdkVersion", 34)
versionCode 1
versionName "0.1.0"
}
Expand Down
19 changes: 0 additions & 19 deletions app.json

This file was deleted.

4 changes: 2 additions & 2 deletions example/App.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import 'react-native-get-random-values';

import { UpgradeMode } from '@playerdata/react-native-mcu-manager';
import React, { useState } from 'react';
import {
Expand All @@ -9,8 +11,6 @@ import {
StyleSheet,
Text,
View,
PermissionsAndroid,
Platform,
} from 'react-native';

import useBluetoothDevices from './src/useBluetoothDevices';
Expand Down
Loading

0 comments on commit d51aabc

Please sign in to comment.