@@ -32548,7 +32548,6 @@ const run = () => __awaiter(void 0, void 0, void 0, function* () {
3254832548 async,
3254932549 'device-locale': deviceLocale,
3255032550 'download-artifacts': downloadArtifacts,
32551- env,
3255232551 'exclude-flows': excludeFlows,
3255332552 'exclude-tags': excludeTags,
3255432553 flows: workspaceFolder,
@@ -32560,9 +32559,24 @@ const run = () => __awaiter(void 0, void 0, void 0, function* () {
3256032559 name,
3256132560 orientation,
3256232561 };
32563- const paramsString = Object.keys(params).reduce((acc, key) => {
32564- return params[key] ? `${acc} --${key} "${params[key]}"` : acc;
32562+ let paramsString = Object.keys(params).reduce((acc, key) => {
32563+ if (!params[key])
32564+ return acc;
32565+ const needsQuotes = typeof params[key] === 'string' &&
32566+ '"' !== params[key][0] &&
32567+ params[key].includes(' ');
32568+ const value = needsQuotes ? `"${params[key]}"` : params[key];
32569+ return `${acc} --${key} ${value}`;
3256532570 }, '');
32571+ if (env && env.length > 0) {
32572+ env.forEach((e) => {
32573+ let [key, value] = e.split('=');
32574+ const needsQuotes = '"' !== value[0] && value.includes(' ');
32575+ if (needsQuotes)
32576+ value = `"${value}"`;
32577+ paramsString += ` --env ${key}=${value}`;
32578+ });
32579+ }
3256632580 (0, child_process_1.execSync)(`npx --yes @devicecloud.dev/dcd cloud ${paramsString} --quiet`, {
3256732581 stdio: 'inherit',
3256832582 });
@@ -32745,9 +32759,7 @@ function getParameters() {
3274532759 if (!(appFilePath !== '') !== (appBinaryId !== '')) {
3274632760 throw new Error('Either app-file or app-binary-id must be used');
3274732761 }
32748- const env = core
32749- .getMultilineInput('env', { required: false })
32750- .join(' --env ');
32762+ const env = core.getMultilineInput('env', { required: false });
3275132763 const androidApiLevel = getAndroidApiLevel(androidApiLevelString);
3275232764 const iOSVersion = getIOSVersion(iOSVersionString);
3275332765 return {
0 commit comments