From 43de7d80dd8431c5a7f52d8507204ef4aea6b6b9 Mon Sep 17 00:00:00 2001 From: Muhamad Rizki Date: Fri, 3 Feb 2023 15:12:44 +0700 Subject: [PATCH] fix: codepush hermes composing sourcemaps command --- src/commands/codepush/lib/react-native-utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/commands/codepush/lib/react-native-utils.ts b/src/commands/codepush/lib/react-native-utils.ts index 9e1d88a5b..9fcf44876 100644 --- a/src/commands/codepush/lib/react-native-utils.ts +++ b/src/commands/codepush/lib/react-native-utils.ts @@ -419,12 +419,12 @@ export async function runHermesEmitBinaryCommand( } return new Promise((resolve, reject) => { - const composeSourceMapsArgs = [sourcemapOutput, jsCompilerSourceMapFile, "-o", sourcemapOutput]; + const composeSourceMapsArgs = [composeSourceMapsPath, sourcemapOutput, jsCompilerSourceMapFile, "-o", sourcemapOutput]; // https://github.com/facebook/react-native/blob/master/react.gradle#L211 // https://github.com/facebook/react-native/blob/master/scripts/react-native-xcode.sh#L178 // packager.sourcemap.map + hbc.sourcemap.map = sourcemap.map - const composeSourceMapsProcess = childProcess.spawn(composeSourceMapsPath, composeSourceMapsArgs); + const composeSourceMapsProcess = childProcess.spawn("node", composeSourceMapsArgs); out.text(`${composeSourceMapsPath} ${composeSourceMapsArgs.join(" ")}`); composeSourceMapsProcess.stdout.on("data", (data: Buffer) => {