Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}) => {
if (process.platform !== 'darwin') {
return log.error('This command can only be used on Mac OS X')
}
deviceConfig.updateDeviceConfig('ios', usePreviousDevice)
if (!host && dev) {
try {
host = getLocalIp()
} catch (e) {
// Swallow
log.debug(e)
}
}
await runMiniApp('ios', {
baseComposite,
descriptor,
dev,
host: host || 'localhost',
mainMiniAppName,
miniapps,
port,
})
}
host?: string
mainMiniAppName?: string
miniapps?: PackagePath[]
port?: string
usePreviousDevice?: boolean
}) => {
deviceConfig.updateDeviceConfig('android', usePreviousDevice)
const miniAppPackageJson = await readPackageJson(process.cwd())
const extraObj =
(extra && (await parseJsonFromStringOrFile(extra))) ||
miniAppPackageJson.ern
? miniAppPackageJson.ern
: {}
await runMiniApp('android', {
baseComposite,
descriptor,
dev,
extra: extraObj,
host,
mainMiniAppName,
miniapps,
port,
})
process.exit(0)
}