Last active
June 10, 2021 19:24
-
-
Save nandorojo/37fea5dca5b6e175571b5e72bb69b20e to your computer and use it in GitHub Desktop.
Expo EAS monorepo patches
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/node_modules/expo-dev-launcher/plugin/build/withDevLauncher.js b/node_modules/expo-dev-launcher/plugin/build/withDevLauncher.js | |
index 04c1d7d..a166618 100644 | |
--- a/node_modules/expo-dev-launcher/plugin/build/withDevLauncher.js | |
+++ b/node_modules/expo-dev-launcher/plugin/build/withDevLauncher.js | |
@@ -20,7 +20,7 @@ const DEV_LAUNCHER_ON_NEW_INTENT = ` | |
`; | |
const DEV_LAUNCHER_WRAPPED_ACTIVITY_DELEGATE = `DevLauncherController.wrapReactActivityDelegate(this, () -> $1);`; | |
const DEV_LAUNCHER_ANDROID_INIT = 'DevLauncherController.initialize(this, getReactNativeHost());'; | |
-const DEV_LAUNCHER_POD_IMPORT = "pod 'expo-dev-launcher', path: '../node_modules/expo-dev-launcher', :configurations => :debug"; | |
+const DEV_LAUNCHER_POD_IMPORT = "pod 'expo-dev-launcher', path: '../../../node_modules/expo-dev-launcher', :configurations => :debug"; | |
async function readFileAsync(path) { | |
return fs_1.default.promises.readFile(path, 'utf8'); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/node_modules/sentry-expo/plugin/build/withSentryAndroid.js b/node_modules/sentry-expo/plugin/build/withSentryAndroid.js | |
index a683bc3..8dc0e88 100644 | |
--- a/node_modules/sentry-expo/plugin/build/withSentryAndroid.js | |
+++ b/node_modules/sentry-expo/plugin/build/withSentryAndroid.js | |
@@ -49,7 +49,7 @@ exports.withSentryAndroid = withSentryAndroid; | |
* We can be confident that the react-native/react.gradle script will be there. | |
*/ | |
function modifyAppBuildGradle(buildGradle) { | |
- if (buildGradle.includes('apply from: "../../node_modules/@sentry/react-native/sentry.gradle"')) { | |
+ if (buildGradle.includes('apply from: "../../../../node_modules/@sentry/react-native/sentry.gradle"')) { | |
return buildGradle; | |
} | |
const pattern = /\n\s*apply from: "\.\.\/\.\.\/node_modules\/react-native\/react\.gradle"/; | |
@@ -57,7 +57,7 @@ function modifyAppBuildGradle(buildGradle) { | |
config_plugins_1.WarningAggregator.addWarningAndroid('sentry-expo', 'Could not find react.gradle script in android/app/build.gradle. Please open a bug report at https://github.com/expo/sentry-expo.'); | |
} | |
return buildGradle.replace(pattern, ` | |
-apply from: "../../node_modules/react-native/react.gradle" | |
-apply from: "../../node_modules/@sentry/react-native/sentry.gradle"`); | |
+apply from: "../../../../node_modules/react-native/react.gradle" | |
+apply from: "../../../../node_modules/@sentry/react-native/sentry.gradle"`); | |
} | |
exports.modifyAppBuildGradle = modifyAppBuildGradle; | |
diff --git a/node_modules/sentry-expo/plugin/build/withSentryIOS.js b/node_modules/sentry-expo/plugin/build/withSentryIOS.js | |
index 5deaccc..ce921a0 100644 | |
--- a/node_modules/sentry-expo/plugin/build/withSentryIOS.js | |
+++ b/node_modules/sentry-expo/plugin/build/withSentryIOS.js | |
@@ -31,7 +31,7 @@ const withSentryIOS = (config, sentryProperties) => { | |
xcodeProject.addBuildPhase([], 'PBXShellScriptBuildPhase', 'Upload Debug Symbols to Sentry', null, { | |
shellPath: '/bin/sh', | |
shellScript: 'export SENTRY_PROPERTIES=sentry.properties\\n' + | |
- '../node_modules/@sentry/cli/bin/sentry-cli upload-dsym', | |
+ '../../../node_modules/@sentry/cli/bin/sentry-cli upload-dsym', | |
}); | |
} | |
let bundleReactNativePhase = xcodeProject.pbxItemByComment('Bundle React Native code and images', 'PBXShellScriptBuildPhase'); | |
@@ -57,7 +57,7 @@ function modifyExistingXcodeBuildScript(script) { | |
code = | |
'export SENTRY_PROPERTIES=sentry.properties\n' + | |
'export EXTRA_PACKAGER_ARGS="--sourcemap-output $DERIVED_FILE_DIR/main.jsbundle.map"\n' + | |
- code.replace(/^.*?\/(packager|scripts)\/react-native-xcode\.sh\s*/m, (match) => `../node_modules/@sentry/cli/bin/sentry-cli react-native xcode ${match}`); | |
+ code.replace(/^.*?\/(packager|scripts)\/react-native-xcode\.sh\s*/m, (match) => `../../../node_modules/@sentry/cli/bin/sentry-cli react-native xcode ${match}`); | |
script.shellScript = JSON.stringify(code); | |
} | |
exports.modifyExistingXcodeBuildScript = modifyExistingXcodeBuildScript; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment