From 5dca3fb26cf6328e7502335c754add284967edc4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oskar=20Kwa=C5=9Bniewski?= Date: Mon, 25 Mar 2024 15:45:10 +0100 Subject: [PATCH] fix: local commands parameters (#134) --- .../react/views/image/localCommands.js | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/image/localCommands.js b/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/image/localCommands.js index e40eeb0e29c986..dc87001156ac06 100644 --- a/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/image/localCommands.js +++ b/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/views/image/localCommands.js @@ -1,43 +1,45 @@ const { - buildOptions, createBuild, createLog, createRun, - logOptions, - runOptions, + getRunOptions, + getLogOptions, + getBuildOptions, } = require('@react-native-community/cli-platform-apple'); +const platformName = 'visionos'; + const run = { name: 'run-visionos', description: 'builds your app and starts it on visionOS simulator', - func: createRun({platformName: 'visionos'}), + func: createRun({platformName}), examples: [ { desc: 'Run on a specific simulator', cmd: 'npx @callstack/react-native-visionos run-visionos --simulator "Apple Vision Pro"', }, ], - options: runOptions, + options: getRunOptions({platformName}), }; const log = { name: 'log-visionos', description: 'starts visionOS device syslog tail', func: createLog({platformName: 'visionos'}), - options: logOptions, + options: getLogOptions({platformName}), }; const build = { name: 'build-visionos', description: 'builds your app for visionOS platform', - func: createBuild({platformName: 'visionos'}), + func: createBuild({platformName}), examples: [ { desc: 'Build the app for all visionOS devices in Release mode', cmd: 'npx @callstack/react-native-visionos build-visionos --mode "Release"', }, ], - options: buildOptions, + options: getBuildOptions({platformName}), }; module.exports = [run, log, build];