@react-native-windows/cli 0.71.4 → 0.71.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Copyright (c) Microsoft Corporation. All rights reserved.
3
+ * Licensed under the MIT License.
4
+ * @format
5
+ */
6
+ export {};
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ /**
3
+ * Copyright (c) Microsoft Corporation. All rights reserved.
4
+ * Licensed under the MIT License.
5
+ * @format
6
+ */
7
+ var __importDefault = (this && this.__importDefault) || function (mod) {
8
+ return (mod && mod.__esModule) ? mod : { "default": mod };
9
+ };
10
+ Object.defineProperty(exports, "__esModule", { value: true });
11
+ const child_process_1 = require("child_process");
12
+ const path_1 = __importDefault(require("path"));
13
+ const commandWithProgress_1 = require("../runWindows/utils/commandWithProgress");
14
+ const healthCheckList_1 = require("../healthCheckList");
15
+ test('Verify list of health checks aligns with rnw-dependencies', async () => {
16
+ const rnwDepScriptPath = path_1.default.join(path_1.default.dirname(require.resolve('react-native-windows/package.json', {
17
+ paths: [process.cwd()],
18
+ })), 'Scripts/rnw-dependencies.ps1');
19
+ const rnwDeps = (0, child_process_1.execSync)(`${commandWithProgress_1.powershell} -ExecutionPolicy Unrestricted -NoProfile "${rnwDepScriptPath}" -NoPrompt -ListChecks`, { stdio: 'pipe' });
20
+ const deps = rnwDeps.toString().trim().split('\n');
21
+ const rnwHelathChecks = deps.map(dep => {
22
+ const match = /([^:]+): ([^:]+): (.*)/.exec(dep);
23
+ if (!match) {
24
+ throw new Error(`Unexpected output from ${rnwDepScriptPath}`);
25
+ }
26
+ const [, optional, id, name] = match;
27
+ return [optional.trim() === 'Required', id, name];
28
+ });
29
+ expect(healthCheckList_1.HealthCheckList).toEqual(rnwHelathChecks);
30
+ });
31
+ //# sourceMappingURL=healthChecks.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"healthChecks.test.js","sourceRoot":"","sources":["../../src/e2etest/healthChecks.test.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;AAEH,iDAAuC;AACvC,gDAAwB;AACxB,iFAAmE;AACnE,wDAAmD;AAEnD,IAAI,CAAC,2DAA2D,EAAE,KAAK,IAAI,EAAE;IAC3E,MAAM,gBAAgB,GAAG,cAAI,CAAC,IAAI,CAChC,cAAI,CAAC,OAAO,CACV,OAAO,CAAC,OAAO,CAAC,mCAAmC,EAAE;QACnD,KAAK,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC;KACvB,CAAC,CACH,EACD,8BAA8B,CAC/B,CAAC;IAEF,MAAM,OAAO,GAAG,IAAA,wBAAQ,EACtB,GAAG,gCAAU,8CAA8C,gBAAgB,yBAAyB,EACpG,EAAC,KAAK,EAAE,MAAM,EAAC,CAChB,CAAC;IACF,MAAM,IAAI,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACnD,MAAM,eAAe,GAAG,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE;QACrC,MAAM,KAAK,GAAG,wBAAwB,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACjD,IAAI,CAAC,KAAK,EAAE;YACV,MAAM,IAAI,KAAK,CAAC,0BAA0B,gBAAgB,EAAE,CAAC,CAAC;SAC/D;QACD,MAAM,CAAC,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,CAAC,GAAG,KAAK,CAAC;QACrC,OAAO,CAAC,QAAQ,CAAC,IAAI,EAAE,KAAK,UAAU,EAAE,EAAE,EAAE,IAAI,CAAC,CAAC;IACpD,CAAC,CAAC,CAAC;IAEH,MAAM,CAAC,iCAAe,CAAC,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;AACnD,CAAC,CAAC,CAAC","sourcesContent":["/**\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n * @format\n */\n\nimport {execSync} from 'child_process';\nimport path from 'path';\nimport {powershell} from '../runWindows/utils/commandWithProgress';\nimport {HealthCheckList} from '../healthCheckList';\n\ntest('Verify list of health checks aligns with rnw-dependencies', async () => {\n const rnwDepScriptPath = path.join(\n path.dirname(\n require.resolve('react-native-windows/package.json', {\n paths: [process.cwd()],\n }),\n ),\n 'Scripts/rnw-dependencies.ps1',\n );\n\n const rnwDeps = execSync(\n `${powershell} -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -NoPrompt -ListChecks`,\n {stdio: 'pipe'},\n );\n const deps = rnwDeps.toString().trim().split('\\n');\n const rnwHelathChecks = deps.map(dep => {\n const match = /([^:]+): ([^:]+): (.*)/.exec(dep);\n if (!match) {\n throw new Error(`Unexpected output from ${rnwDepScriptPath}`);\n }\n const [, optional, id, name] = match;\n return [optional.trim() === 'Required', id, name];\n });\n\n expect(HealthCheckList).toEqual(rnwHelathChecks);\n});\n"]}
@@ -0,0 +1 @@
1
+ export declare const HealthCheckList: (string | boolean)[][];
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.HealthCheckList = void 0;
4
+ // Store list of health checks here to avoid having to launch PowerShell on every react-native config call
5
+ exports.HealthCheckList = [
6
+ [false, "FreeSpace", "Free space on current drive > 15 GB"],
7
+ [false, "InstalledMemory", "Installed memory >= 16 GB"],
8
+ [true, "WindowsVersion", "Windows version >= 10.0.16299.0"],
9
+ [true, "DeveloperMode", "Developer mode is on"],
10
+ [true, "LongPath", "Long path support is enabled"],
11
+ [true, "VSUWP", "Visual Studio 2022 (>= 17.3) & req. components"],
12
+ [true, "Node", "Node.js (LTS, >= 14.0)"],
13
+ [true, "Yarn", "Yarn"],
14
+ [true, "DotNetCore", ".NET SDK (LTS, = 6.0)"]
15
+ ];
16
+ //# sourceMappingURL=healthCheckList.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"healthCheckList.js","sourceRoot":"","sources":["../src/healthCheckList.ts"],"names":[],"mappings":";;;AAAA,0GAA0G;AAC7F,QAAA,eAAe,GAAG;IAC7B,CAAC,KAAK,EAAE,WAAW,EAAE,qCAAqC,CAAC;IAC3D,CAAC,KAAK,EAAE,iBAAiB,EAAE,2BAA2B,CAAC;IACvD,CAAC,IAAI,EAAE,gBAAgB,EAAE,iCAAiC,CAAC;IAC3D,CAAC,IAAI,EAAE,eAAe,EAAE,sBAAsB,CAAC;IAC/C,CAAC,IAAI,EAAE,UAAU,EAAE,8BAA8B,CAAC;IAClD,CAAC,IAAI,EAAE,OAAO,EAAE,gDAAgD,CAAC;IACjE,CAAC,IAAI,EAAE,MAAM,EAAE,wBAAwB,CAAC;IACxC,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,CAAC;IACtB,CAAC,IAAI,EAAE,YAAY,EAAE,uBAAuB,CAAC;CAC9C,CAAA","sourcesContent":["// Store list of health checks here to avoid having to launch PowerShell on every react-native config call\nexport const HealthCheckList = [\n [false, \"FreeSpace\", \"Free space on current drive > 15 GB\"],\n [false, \"InstalledMemory\", \"Installed memory >= 16 GB\"],\n [true, \"WindowsVersion\", \"Windows version >= 10.0.16299.0\"],\n [true, \"DeveloperMode\", \"Developer mode is on\"],\n [true, \"LongPath\", \"Long path support is enabled\"],\n [true, \"VSUWP\", \"Visual Studio 2022 (>= 17.3) & req. components\"],\n [true, \"Node\", \"Node.js (LTS, >= 14.0)\"],\n [true, \"Yarn\", \"Yarn\"],\n [true, \"DotNetCore\", \".NET SDK (LTS, = 6.0)\"]\n]\n"]}
@@ -5,12 +5,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.getHealthChecks = void 0;
7
7
  const path_1 = __importDefault(require("path"));
8
- const child_process_1 = require("child_process");
9
8
  const rnDir = path_1.default.dirname(require.resolve('react-native/package.json', { paths: [process.cwd()] }));
10
9
  const cliDir = path_1.default.dirname(require.resolve('@react-native-community/cli/package.json', { paths: [rnDir] }));
11
10
  const execaPath = require.resolve('execa', { paths: [cliDir] });
12
11
  const execa = require(execaPath);
13
12
  const commandWithProgress_1 = require("./runWindows/utils/commandWithProgress");
13
+ const healthCheckList_1 = require("./healthCheckList");
14
14
  function getHealthChecks() {
15
15
  // #8471: There are known cases where the dependencies script will error out.
16
16
  // Fail gracefully if that happens in the meantime.
@@ -35,26 +35,20 @@ function getHealthChecksUnsafe() {
35
35
  return undefined;
36
36
  }
37
37
  const rnwDepScriptPath = path_1.default.join(path_1.default.dirname(require.resolve('react-native-windows/package.json', { paths: [process.cwd()] })), 'Scripts/rnw-dependencies.ps1');
38
- const rnwDeps = (0, child_process_1.execSync)(`${commandWithProgress_1.powershell} -ExecutionPolicy Unrestricted -NoProfile "${rnwDepScriptPath}" -NoPrompt -ListChecks`, { stdio: 'pipe' });
39
- const deps = rnwDeps.toString().trim().split('\n');
40
38
  return [
41
39
  {
42
40
  label: 'Windows',
43
- healthchecks: deps.map(dep => {
44
- const match = /([^:]+): ([^:]+): (.*)/.exec(dep);
45
- if (!match) {
46
- throw new Error(`Unexpected output from ${rnwDepScriptPath}`);
47
- }
48
- const [, /*optional*/ , id, name] = match;
41
+ healthchecks: healthCheckList_1.HealthCheckList.map((dep) => {
42
+ const [optional, id, name] = dep;
49
43
  return {
50
44
  label: name,
51
45
  // The schema check of react-native doctor requires this to be a string, although it should be a boolean
52
46
  // Enable this once we pick up a new version of the CLI that includes https://github.com/react-native-community/cli/pull/1367
53
- // isRequired: (optional.trim() === 'Required') ? true : false,
47
+ isRequired: optional,
54
48
  getDiagnostics: async () => {
55
49
  let needsToBeFixed = true;
56
50
  try {
57
- await execa(`${commandWithProgress_1.powershell} -ExecutionPolicy Unrestricted -NoProfile "${rnwDepScriptPath}" -NoPrompt -Check ${id}`);
51
+ await execa(`"${commandWithProgress_1.powershell}" -ExecutionPolicy Unrestricted -NoProfile "${rnwDepScriptPath}" -NoPrompt -Check ${id}`);
58
52
  needsToBeFixed = false;
59
53
  }
60
54
  catch (_a) {
@@ -1 +1 @@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gCAAU,8CAA8C,gBAAgB,YAAY,EAAE,EAAE,CAAC;wBAC5G,IAAI;4BACF,MAAM,EAAE,QAAQ,EAAE,GAAG,MAAM,KAAK,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;4BAChE,IAAI,QAAQ,EAAE;gCACZ,qBAAqB,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,oCAAoC,EAAE,GAAG,EAAE,CAAC,CAAC;gCAC3F,MAAM,CAAC,IAAI,EAAE,CAAC;6BACf;iCAAM;gCACL,MAAM,CAAC,OAAO,EAAE,CAAC;6BAClB;yBACF;wBAAC,WAAM;4BACN,qBAAqB,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,oCAAoC,EAAE,GAAG,EAAE,CAAC,CAAC;4BAC3F,MAAM,CAAC,IAAI,EAAE,CAAC;yBACf;oBACH,CAAC;iBACF,CAAA;YACH,CAAC,CAAC;SACL;KAAC,CAAC;AACP,CAAC","sourcesContent":["import path from 'path';\n\nimport { execSync} from 'child_process';\n\nconst rnDir = path.dirname(require.resolve('react-native/package.json', {paths: [process.cwd()]}));\nconst cliDir = path.dirname(require.resolve('@react-native-community/cli/package.json', {paths: [rnDir]}));\nconst execaPath = require.resolve('execa', { paths: [cliDir] });\nconst execa = require(execaPath);\n\nimport type {HealthCheckCategory} from '@react-native-community/cli-doctor/build/types';\nimport { powershell } from './runWindows/utils/commandWithProgress';\n\nexport function getHealthChecks(): HealthCheckCategory[] | undefined {\n // #8471: There are known cases where the dependencies script will error out.\n // Fail gracefully if that happens in the meantime.\n try {\n return getHealthChecksUnsafe();\n } catch {\n return [{\n label: 'Windows',\n healthchecks: [{\n label: 'Failed to enumerate health checks',\n getDiagnostics: async () => ({needsToBeFixed: true}),\n runAutomaticFix: async ({loader}) => {loader.fail()},\n }]\n }];\n }\n}\n\nfunction getHealthChecksUnsafe(): HealthCheckCategory[] | undefined {\n// All our health checks are windows only...\n if (process.platform !== 'win32') {\n return undefined;\n }\n\n const rnwDepScriptPath = path.join(path.dirname(require.resolve(\n 'react-native-windows/package.json',\n {paths: [process.cwd()]})), 'Scripts/rnw-dependencies.ps1');\n \n const rnwDeps = execSync(`${powershell} -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -NoPrompt -ListChecks`, {stdio: 'pipe'});\n const deps = rnwDeps.toString().trim().split('\\n');\n return [\n {\n label: 'Windows',\n healthchecks:\n deps.map(dep => {\n const match = /([^:]+): ([^:]+): (.*)/.exec(dep);\n if (!match) {\n throw new Error(`Unexpected output from ${rnwDepScriptPath}`);\n }\n const [, /*optional*/, id, name] = match;\n return {\n label: name,\n // The schema check of react-native doctor requires this to be a string, although it should be a boolean\n // Enable this once we pick up a new version of the CLI that includes https://github.com/react-native-community/cli/pull/1367\n // isRequired: (optional.trim() === 'Required') ? true : false, \n getDiagnostics: async () => {\n let needsToBeFixed = true;\n try {\n await execa(`${powershell} -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -NoPrompt -Check ${id}`);\n needsToBeFixed = false;\n } catch {\n }\n return {\n needsToBeFixed,\n }\n },\n runAutomaticFix: async ({ loader, logManualInstallation }) => {\n const command = `${powershell} -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -Check ${id}`;\n try {\n const { exitCode } = await execa(command, { stdio: 'inherit' });\n if (exitCode) {\n logManualInstallation({ command, healthcheck: `react-native-windows dependency \"${id}\"` });\n loader.fail();\n } else {\n loader.succeed();\n }\n } catch {\n logManualInstallation({ command, healthcheck: `react-native-windows dependency \"${id}\"` });\n loader.fail();\n }\n }\n }\n })\n }];\n }"]}
1
+ {"version":3,"file":"healthChecks.js","sourceRoot":"","sources":["../src/healthChecks.ts"],"names":[],"mappings":";;;;;;AAAA,gDAAwB;AAExB,MAAM,KAAK,GAAG,cAAI,CAAC,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,2BAA2B,EAAE,EAAC,KAAK,EAAE,CAAC,OAAO,CAAC,GAAG,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path';\n\nconst rnDir = path.dirname(require.resolve('react-native/package.json', {paths: [process.cwd()]}));\nconst cliDir = path.dirname(require.resolve('@react-native-community/cli/package.json', {paths: [rnDir]}));\nconst execaPath = require.resolve('execa', { paths: [cliDir] });\nconst execa = require(execaPath);\n\nimport type {HealthCheckCategory, HealthCheckInterface} from '@react-native-community/cli-doctor/build/types';\nimport { powershell } from './runWindows/utils/commandWithProgress';\nimport { HealthCheckList } from './healthCheckList';\n\nexport function getHealthChecks(): HealthCheckCategory[] | undefined {\n // #8471: There are known cases where the dependencies script will error out.\n // Fail gracefully if that happens in the meantime.\n try {\n return getHealthChecksUnsafe();\n } catch {\n return [{\n label: 'Windows',\n healthchecks: [{\n label: 'Failed to enumerate health checks',\n getDiagnostics: async () => ({needsToBeFixed: true}),\n runAutomaticFix: async ({loader}) => {loader.fail()},\n }]\n }];\n }\n}\n\nfunction getHealthChecksUnsafe(): HealthCheckCategory[] | undefined {\n// All our health checks are windows only...\n if (process.platform !== 'win32') {\n return undefined;\n }\n\n const rnwDepScriptPath = path.join(path.dirname(require.resolve(\n 'react-native-windows/package.json',\n {paths: [process.cwd()]})), 'Scripts/rnw-dependencies.ps1');\n \n return [\n {\n label: 'Windows',\n healthchecks:\n HealthCheckList.map((dep: [boolean, string, string]) => {\n const [optional, id, name] = dep;\n return {\n label: name,\n // The schema check of react-native doctor requires this to be a string, although it should be a boolean\n // Enable this once we pick up a new version of the CLI that includes https://github.com/react-native-community/cli/pull/1367\n isRequired: optional, \n getDiagnostics: async () => {\n let needsToBeFixed = true;\n try {\n await execa(`\"${powershell}\" -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -NoPrompt -Check ${id}`);\n needsToBeFixed = false;\n } catch {\n }\n return {\n needsToBeFixed,\n }\n },\n runAutomaticFix: async ({ loader, logManualInstallation }) => {\n const command = `${powershell} -ExecutionPolicy Unrestricted -NoProfile \"${rnwDepScriptPath}\" -Check ${id}`;\n try {\n const { exitCode } = await execa(command, { stdio: 'inherit' });\n if (exitCode) {\n logManualInstallation({ command, healthcheck: `react-native-windows dependency \"${id}\"` });\n loader.fail();\n } else {\n loader.succeed();\n }\n } catch {\n logManualInstallation({ command, healthcheck: `react-native-windows dependency \"${id}\"` });\n loader.fail();\n }\n }\n } as HealthCheckInterface\n })\n }];\n }"]}
@@ -23,7 +23,11 @@ exports.runWindowsOptions = [
23
23
  {
24
24
  name: '--arch [string]',
25
25
  description: 'The build architecture (ARM64, x86, x64)',
26
- default: os_1.default.arch(),
26
+ default: os_1.default.arch() === 'ia32'
27
+ ? 'x86'
28
+ : os_1.default.arch() === 'arm64'
29
+ ? 'ARM64'
30
+ : os_1.default.arch(),
27
31
  parse: parseBuildArch,
28
32
  },
29
33
  {
@@ -1 +1 @@
1
- {"version":3,"file":"runWindowsOptions.js","sourceRoot":"","sources":["../../src/runWindows/runWindowsOptions.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAEH,4CAAoB;AAsDP,QAAA,iBAAiB,GAAoB;IAChD;QACE,IAAI,EAAE,WAAW;QACjB,WAAW,EAAE,2BAA2B;KACzC;IACD;QACE,IAAI,EAAE,iBAAiB;QACvB,WAAW,EACT,sFAAsF;QACxF,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,IAAI;KAC/B;IACD;QACE,IAAI,EAAE,iBAAiB;QACvB,WAAW,EAAE,0CAA0C;QACvD,OAAO,EAAE,YAAE,CAAC,IAAI,EAAE;QAClB,KAAK,EAAE,cAAc;KACtB;IACD;QACE,IAAI,EAAE,cAAc;QACpB,WAAW,EAAE,2BAA2B;KACzC;IACD;QACE,IAAI,EAAE,YAAY;QAClB,WAAW,EAAE,gCAAgC;KAC9C;IACD;QACE,IAAI,EAAE,UAAU;QAChB,WAAW,EAAE,uCAAuC;KACrD;IACD;QACE,IAAI,EAAE,mBAAmB;QACzB,WAAW,EAAE,qDAAqD;KACnE;IACD;QACE,IAAI,EAAE,oBAAoB;QAC1B,WAAW,EAAE,2CAA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AAE;YACjD,OAAO,SAAS,CAAC;SAClB;KACF;IAED,QAAQ,CAAC,wBAAwB,GAAG,sBAAsB,eAAe,EAAE,CAAC,CAAC;AAC/E,CAAC;AAED,SAAS,wBAAwB,CAAC,GAAW;IAC3C,MAAM,GAAG,GAAG,QAAQ,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;IAE9B,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE;QAC1B,QAAQ,CAAC,uDAAuD,CAAC,CAAC;KACnE;IACD,IAAI,GAAG,GAAG,IAAI,IAAI,GAAG,IAAI,KAAK,EAAE;QAC9B,QAAQ,CAAC,uCAAuC,CAAC,CAAC;KACnD;IAED,OAAO,GAAG,CAAC;AACb,CAAC;AAED,SAAS,QAAQ,CAAC,GAAW;IAC3B,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACnB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC","sourcesContent":["/**\n * Copyright (c) Microsoft Corporation.\n * Licensed under the MIT License.\n * @format\n */\n\nimport os from 'os';\nimport {CommandOption} from '@react-native-community/cli-types';\n\nexport type BuildArch = 'x86' | 'x64' | 'ARM64';\nexport type BuildConfig = 'Debug' | 'DebugBundle' | 'Release' | 'ReleaseBundle';\n\n/**\n * * Options are the following:\n * release: Boolean - Specifies release build\n * root: String - The root of the application\n * arch: String - The build architecture (ARM64, x86, x64)\n * singleproc: Boolean - opt out of multi-proc builds\n * emulator: Boolean - Deploy to the emulator\n * device: Boolean - Deploy to a device\n * target: String - Device GUID to deploy to\n * remote-debugging: Boolean - Run using remote JS proxy\n * logging: Boolean - Enables logging\n * no-packager: Boolean - Do not launch packager while building\n * bundle: Boolean - Enable Bundle configuration.\n * no-launch: Boolean - Do not launch the app after deployment\n * no-build: Boolean - Do not build the solution\n * no-deploy: Boolean - Do not deploy the app\n * deploy-from-layout: Force deploy from layout, even in release builds\n * sln: String - Solution file to build\n * msbuildprops: String - Comma separated props to pass to msbuild, eg: prop1=value1,prop2=value2\n * direct-debugging: Number - Enable direct debugging on specified port\n * no-telemetry: Boolean - Disables sending telemetry that allows analysis of usage and failures of the react-native-windows CLI\n */\nexport interface RunWindowsOptions {\n release?: boolean;\n root: string;\n arch: BuildArch;\n singleproc?: boolean;\n emulator?: boolean;\n device?: boolean;\n target?: string;\n remoteDebugging?: string;\n logging?: boolean;\n packager?: boolean;\n bundle?: boolean;\n launch?: boolean;\n autolink?: boolean;\n build?: boolean;\n deploy?: boolean;\n deployFromLayout?: boolean;\n sln?: string;\n proj?: string;\n msbuildprops?: string;\n buildLogDirectory?: string;\n info?: boolean;\n directDebugging?: number;\n telemetry?: boolean;\n}\n\nexport const runWindowsOptions: CommandOption[] = [\n {\n name: '--release',\n description: 'Specifies a release build',\n },\n {\n name: '--root [string]',\n description:\n 'Override the root directory for the windows build which contains the windows folder.',\n default: config => config.root,\n },\n {\n name: '--arch [string]',\n description: 'The build architecture (ARM64, x86, x64)',\n default: os.arch(),\n parse: parseBuildArch,\n },\n {\n name: '--singleproc',\n description: 'Disables multi-proc build',\n },\n {\n name: '--emulator',\n description: 'Deploys the app to an emulator',\n },\n {\n name: '--device',\n description: 'Deploys the app to a connected device',\n },\n {\n name: '--target [string]',\n description: 'Deploys the app to the specified GUID for a device.',\n },\n {\n name: '--remote-debugging',\n description: 'Deploys the app in remote debugging mode.',\n },\n {\n name: '--logging',\n description: 'Enables logging',\n },\n {\n name: '--no-packager',\n description: 'Do not launch packager while building',\n },\n {\n name: '--bundle',\n description:\n 'Enable Bundle configuration and it would be ReleaseBundle/DebugBundle other than Release/Debug',\n },\n {\n name: '--no-launch',\n description: 'Do not launch the app after deployment',\n },\n {\n name: '--no-autolink',\n description: 'Do not run autolinking',\n },\n {\n name: '--no-build',\n description: 'Do not build the solution',\n },\n {\n name: '--no-deploy',\n description: 'Do not deploy the app',\n },\n {\n name: '--deploy-from-layout',\n description: 'Force deploy from layout',\n },\n {\n name: '--sln [string]',\n description:\n \"Override the app solution file determined by 'react-native config', e.g. windows\\\\myApp.sln\",\n default: undefined,\n },\n {\n name: '--proj [string]',\n description:\n \"Override the app project file determined by 'react-native config', e.g. windows\\\\myApp\\\\myApp.vcxproj\",\n default: undefined,\n },\n {\n name: '--msbuildprops [string]',\n description:\n 'Comma separated props to pass to msbuild, eg: prop1=value1,prop2=value2',\n },\n {\n name: '--buildLogDirectory [string]',\n description: 'Optional directory where msbuild log files should be stored',\n },\n {\n name: '--info',\n description: 'Dump environment information',\n },\n {\n name: '--direct-debugging [number]',\n description: 'Enable direct debugging on specified port',\n parse: parseDirectDebuggingPort,\n },\n {\n name: '--no-telemetry',\n description:\n 'Disables sending telemetry that allows analysis of usage and failures of the react-native-windows CLI',\n },\n];\n\nfunction parseBuildArch(arg: string): BuildArch {\n const supportedArches: BuildArch[] = ['x86', 'x64', 'ARM64'];\n for (const supported of supportedArches) {\n if (arg.toLowerCase() === supported.toLowerCase()) {\n return supported;\n }\n }\n\n errorOut(`Unrecognized --arch '${arg}'. Expected one of ${supportedArches}`);\n}\n\nfunction parseDirectDebuggingPort(arg: string): number {\n const num = parseInt(arg, 10);\n\n if (!Number.isInteger(num)) {\n errorOut(`Expected argument '--direct-debugging' to be a number`);\n }\n if (num < 1024 || num >= 65535) {\n errorOut('Direct debugging port it out of range');\n }\n\n return num;\n}\n\nfunction errorOut(arg: string): never {\n console.error(arg);\n process.exit(1);\n}\n"]}
1
+ {"version":3,"file":"runWindowsOptions.js","sourceRoot":"","sources":["../../src/runWindows/runWindowsOptions.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;AAEH,4CAAoB;AAsDP,QAAA,iBAAiB,GAAoB;IAChD;QACE,IAAI,EAAE,WAAW;QACjB,WAAW,EAAE,2BAA2B;KACzC;IACD;QACE,IAAI,EAAE,iBAAiB;QACvB,WAAW,EACT,sFAAsF;QACxF,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,IAAI;KAC/B;IACD;QACE,IAA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\n */\n\nimport os from 'os';\nimport {CommandOption} from '@react-native-community/cli-types';\n\nexport type BuildArch = 'x86' | 'x64' | 'ARM64';\nexport type BuildConfig = 'Debug' | 'DebugBundle' | 'Release' | 'ReleaseBundle';\n\n/**\n * * Options are the following:\n * release: Boolean - Specifies release build\n * root: String - The root of the application\n * arch: String - The build architecture (ARM64, x86, x64)\n * singleproc: Boolean - opt out of multi-proc builds\n * emulator: Boolean - Deploy to the emulator\n * device: Boolean - Deploy to a device\n * target: String - Device GUID to deploy to\n * remote-debugging: Boolean - Run using remote JS proxy\n * logging: Boolean - Enables logging\n * no-packager: Boolean - Do not launch packager while building\n * bundle: Boolean - Enable Bundle configuration.\n * no-launch: Boolean - Do not launch the app after deployment\n * no-build: Boolean - Do not build the solution\n * no-deploy: Boolean - Do not deploy the app\n * deploy-from-layout: Force deploy from layout, even in release builds\n * sln: String - Solution file to build\n * msbuildprops: String - Comma separated props to pass to msbuild, eg: prop1=value1,prop2=value2\n * direct-debugging: Number - Enable direct debugging on specified port\n * no-telemetry: Boolean - Disables sending telemetry that allows analysis of usage and failures of the react-native-windows CLI\n */\nexport interface RunWindowsOptions {\n release?: boolean;\n root: string;\n arch: BuildArch;\n singleproc?: boolean;\n emulator?: boolean;\n device?: boolean;\n target?: string;\n remoteDebugging?: string;\n logging?: boolean;\n packager?: boolean;\n bundle?: boolean;\n launch?: boolean;\n autolink?: boolean;\n build?: boolean;\n deploy?: boolean;\n deployFromLayout?: boolean;\n sln?: string;\n proj?: string;\n msbuildprops?: string;\n buildLogDirectory?: string;\n info?: boolean;\n directDebugging?: number;\n telemetry?: boolean;\n}\n\nexport const runWindowsOptions: CommandOption[] = [\n {\n name: '--release',\n description: 'Specifies a release build',\n },\n {\n name: '--root [string]',\n description:\n 'Override the root directory for the windows build which contains the windows folder.',\n default: config => config.root,\n },\n {\n name: '--arch [string]',\n description: 'The build architecture (ARM64, x86, x64)',\n default:\n os.arch() === 'ia32'\n ? 'x86'\n : os.arch() === 'arm64'\n ? 'ARM64'\n : os.arch(),\n parse: parseBuildArch,\n },\n {\n name: '--singleproc',\n description: 'Disables multi-proc build',\n },\n {\n name: '--emulator',\n description: 'Deploys the app to an emulator',\n },\n {\n name: '--device',\n description: 'Deploys the app to a connected device',\n },\n {\n name: '--target [string]',\n description: 'Deploys the app to the specified GUID for a device.',\n },\n {\n name: '--remote-debugging',\n description: 'Deploys the app in remote debugging mode.',\n },\n {\n name: '--logging',\n description: 'Enables logging',\n },\n {\n name: '--no-packager',\n description: 'Do not launch packager while building',\n },\n {\n name: '--bundle',\n description:\n 'Enable Bundle configuration and it would be ReleaseBundle/DebugBundle other than Release/Debug',\n },\n {\n name: '--no-launch',\n description: 'Do not launch the app after deployment',\n },\n {\n name: '--no-autolink',\n description: 'Do not run autolinking',\n },\n {\n name: '--no-build',\n description: 'Do not build the solution',\n },\n {\n name: '--no-deploy',\n description: 'Do not deploy the app',\n },\n {\n name: '--deploy-from-layout',\n description: 'Force deploy from layout',\n },\n {\n name: '--sln [string]',\n description:\n \"Override the app solution file determined by 'react-native config', e.g. windows\\\\myApp.sln\",\n default: undefined,\n },\n {\n name: '--proj [string]',\n description:\n \"Override the app project file determined by 'react-native config', e.g. windows\\\\myApp\\\\myApp.vcxproj\",\n default: undefined,\n },\n {\n name: '--msbuildprops [string]',\n description:\n 'Comma separated props to pass to msbuild, eg: prop1=value1,prop2=value2',\n },\n {\n name: '--buildLogDirectory [string]',\n description: 'Optional directory where msbuild log files should be stored',\n },\n {\n name: '--info',\n description: 'Dump environment information',\n },\n {\n name: '--direct-debugging [number]',\n description: 'Enable direct debugging on specified port',\n parse: parseDirectDebuggingPort,\n },\n {\n name: '--no-telemetry',\n description:\n 'Disables sending telemetry that allows analysis of usage and failures of the react-native-windows CLI',\n },\n];\n\nfunction parseBuildArch(arg: string): BuildArch {\n const supportedArches: BuildArch[] = ['x86', 'x64', 'ARM64'];\n for (const supported of supportedArches) {\n if (arg.toLowerCase() === supported.toLowerCase()) {\n return supported;\n }\n }\n\n errorOut(`Unrecognized --arch '${arg}'. Expected one of ${supportedArches}`);\n}\n\nfunction parseDirectDebuggingPort(arg: string): number {\n const num = parseInt(arg, 10);\n\n if (!Number.isInteger(num)) {\n errorOut(`Expected argument '--direct-debugging' to be a number`);\n }\n if (num < 1024 || num >= 65535) {\n errorOut('Direct debugging port it out of range');\n }\n\n return num;\n}\n\nfunction errorOut(arg: string): never {\n console.error(arg);\n process.exit(1);\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-native-windows/cli",
3
- "version": "0.71.4",
3
+ "version": "0.71.6",
4
4
  "license": "MIT",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "repository": {