eas-cli 0.29.0 → 0.31.0

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.
Files changed (148) hide show
  1. package/README.md +26 -26
  2. package/build/analytics.js +6 -9
  3. package/build/build/android/build.js +6 -8
  4. package/build/build/android/configure.d.ts +6 -1
  5. package/build/build/android/configure.js +31 -5
  6. package/build/build/android/prepareJob.js +3 -3
  7. package/build/build/android/version.d.ts +15 -0
  8. package/build/build/android/version.js +75 -1
  9. package/build/build/context.d.ts +2 -0
  10. package/build/build/context.js +8 -0
  11. package/build/build/ios/UpdatesModule.js +3 -1
  12. package/build/build/ios/configure.js +1 -1
  13. package/build/build/ios/credentials.js +2 -7
  14. package/build/build/ios/prepareJob.js +3 -14
  15. package/build/build/ios/version.d.ts +1 -1
  16. package/build/build/ios/version.js +5 -23
  17. package/build/build/utils/printBuildInfo.js +1 -1
  18. package/build/build/utils/updates.js +1 -1
  19. package/build/build/utils/version.d.ts +7 -0
  20. package/build/build/utils/version.js +37 -0
  21. package/build/commands/branch/create.js +1 -4
  22. package/build/commands/branch/delete.js +1 -4
  23. package/build/commands/branch/list.js +1 -4
  24. package/build/commands/branch/publish.js +2 -5
  25. package/build/commands/branch/rename.js +1 -4
  26. package/build/commands/branch/view.js +1 -4
  27. package/build/commands/build/cancel.js +1 -2
  28. package/build/commands/build/configure.js +2 -2
  29. package/build/commands/build/index.js +15 -6
  30. package/build/commands/build/list.js +1 -2
  31. package/build/commands/build/view.js +1 -2
  32. package/build/commands/channel/create.js +1 -4
  33. package/build/commands/channel/edit.js +1 -4
  34. package/build/commands/channel/list.js +1 -4
  35. package/build/commands/channel/rollout.js +1 -4
  36. package/build/commands/channel/view.js +1 -4
  37. package/build/commands/config.js +1 -2
  38. package/build/commands/credentials.js +5 -1
  39. package/build/commands/device/list.js +1 -2
  40. package/build/commands/device/view.js +1 -2
  41. package/build/commands/project/info.js +1 -4
  42. package/build/commands/project/init.js +1 -4
  43. package/build/commands/secret/create.js +1 -2
  44. package/build/commands/secret/delete.js +1 -2
  45. package/build/commands/secret/list.js +1 -2
  46. package/build/commands/submit.js +2 -3
  47. package/build/commands/webhook/create.js +1 -4
  48. package/build/commands/webhook/delete.js +1 -4
  49. package/build/commands/webhook/list.js +1 -4
  50. package/build/credentials/android/AndroidCredentialsProvider.d.ts +2 -2
  51. package/build/credentials/android/actions/AssignFcm.d.ts +2 -2
  52. package/build/credentials/android/actions/AssignGoogleServiceAccountKey.d.ts +8 -0
  53. package/build/credentials/android/actions/AssignGoogleServiceAccountKey.js +19 -0
  54. package/build/credentials/android/actions/BuildCredentialsUtils.d.ts +5 -5
  55. package/build/credentials/android/actions/CreateFcm.d.ts +2 -2
  56. package/build/credentials/android/actions/CreateGoogleServiceAccountKey.d.ts +3 -2
  57. package/build/credentials/android/actions/CreateGoogleServiceAccountKey.js +19 -11
  58. package/build/credentials/android/actions/CreateKeystore.d.ts +2 -2
  59. package/build/credentials/android/actions/DownloadKeystore.d.ts +3 -3
  60. package/build/credentials/android/actions/RemoveFcm.d.ts +2 -2
  61. package/build/credentials/android/actions/RemoveGoogleServiceAccountKey.d.ts +13 -0
  62. package/build/credentials/android/actions/RemoveGoogleServiceAccountKey.js +48 -0
  63. package/build/credentials/android/actions/RemoveKeystore.d.ts +2 -2
  64. package/build/credentials/android/actions/SetupBuildCredentials.d.ts +5 -5
  65. package/build/credentials/android/actions/SetupBuildCredentialsFromCredentialsJson.d.ts +2 -2
  66. package/build/credentials/android/actions/SetupGoogleServiceAccountKey.d.ts +10 -0
  67. package/build/credentials/android/actions/SetupGoogleServiceAccountKey.js +59 -0
  68. package/build/credentials/android/actions/UpdateCredentialsJson.d.ts +2 -2
  69. package/build/credentials/android/actions/UseExistingGoogleServiceAccountKey.d.ts +8 -0
  70. package/build/credentials/android/actions/UseExistingGoogleServiceAccountKey.js +23 -0
  71. package/build/credentials/android/api/GraphqlClient.d.ts +5 -2
  72. package/build/credentials/android/api/GraphqlClient.js +20 -3
  73. package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.d.ts +1 -0
  74. package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.js +26 -0
  75. package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.d.ts +1 -0
  76. package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.js +17 -0
  77. package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.d.ts +4 -0
  78. package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.js +31 -0
  79. package/build/credentials/android/credentials.d.ts +2 -0
  80. package/build/credentials/android/utils/googleServiceAccountKey.d.ts +3 -0
  81. package/build/credentials/android/utils/googleServiceAccountKey.js +90 -1
  82. package/build/credentials/android/utils/printCredentials.js +67 -28
  83. package/build/credentials/context.d.ts +17 -21
  84. package/build/credentials/context.js +21 -26
  85. package/build/credentials/credentialsJson/update.d.ts +3 -3
  86. package/build/credentials/ios/IosCredentialsProvider.d.ts +2 -2
  87. package/build/credentials/ios/actions/AppleTeamUtils.d.ts +2 -2
  88. package/build/credentials/ios/actions/AssignPushKey.d.ts +2 -2
  89. package/build/credentials/ios/actions/BuildCredentialsUtils.d.ts +8 -8
  90. package/build/credentials/ios/actions/ConfigureProvisioningProfile.d.ts +2 -2
  91. package/build/credentials/ios/actions/CreateDistributionCertificate.d.ts +2 -2
  92. package/build/credentials/ios/actions/CreateProvisioningProfile.d.ts +2 -2
  93. package/build/credentials/ios/actions/CreatePushKey.d.ts +2 -2
  94. package/build/credentials/ios/actions/DistributionCertificateUtils.d.ts +4 -4
  95. package/build/credentials/ios/actions/DistributionCertificateUtils.js +3 -3
  96. package/build/credentials/ios/actions/ProvisioningProfileUtils.d.ts +2 -2
  97. package/build/credentials/ios/actions/PushKeyUtils.d.ts +4 -4
  98. package/build/credentials/ios/actions/RemoveDistributionCertificate.d.ts +3 -3
  99. package/build/credentials/ios/actions/RemoveProvisioningProfile.d.ts +2 -2
  100. package/build/credentials/ios/actions/RemovePushKey.d.ts +3 -3
  101. package/build/credentials/ios/actions/SetupAdhocProvisioningProfile.d.ts +4 -3
  102. package/build/credentials/ios/actions/SetupAdhocProvisioningProfile.js +48 -4
  103. package/build/credentials/ios/actions/SetupBuildCredentials.d.ts +2 -2
  104. package/build/credentials/ios/actions/SetupBuildCredentialsFromCredentialsJson.d.ts +2 -2
  105. package/build/credentials/ios/actions/SetupDistributionCertificate.d.ts +3 -3
  106. package/build/credentials/ios/actions/SetupInternalProvisioningProfile.d.ts +2 -2
  107. package/build/credentials/ios/actions/SetupProvisioningProfile.d.ts +6 -6
  108. package/build/credentials/ios/actions/SetupPushKey.d.ts +3 -3
  109. package/build/credentials/ios/actions/SetupTargetBuildCredentials.d.ts +4 -4
  110. package/build/credentials/ios/actions/SetupTargetBuildCredentialsFromCredentialsJson.d.ts +5 -5
  111. package/build/credentials/ios/actions/UpdateCredentialsJson.d.ts +2 -2
  112. package/build/credentials/ios/appstore/AppStoreApi.d.ts +4 -15
  113. package/build/credentials/ios/appstore/AppStoreApi.js +4 -12
  114. package/build/credentials/ios/appstore/entitlements.js +14 -13
  115. package/build/credentials/ios/utils/printCredentials.js +83 -51
  116. package/build/credentials/ios/validators/validateDistributionCertificate.d.ts +2 -2
  117. package/build/credentials/ios/validators/validateProvisioningProfile.d.ts +2 -2
  118. package/build/credentials/ios/validators/validatePushKey.d.ts +2 -2
  119. package/build/credentials/manager/HelperActions.d.ts +4 -0
  120. package/build/credentials/manager/ManageAndroid.d.ts +18 -12
  121. package/build/credentials/manager/ManageAndroid.js +72 -10
  122. package/build/credentials/manager/ManageIos.d.ts +3 -2
  123. package/build/credentials/manager/SelectAndroidBuildCredentials.d.ts +3 -3
  124. package/build/credentials/manager/SelectBuildProfileFromEasJson.d.ts +3 -4
  125. package/build/credentials/manager/SelectBuildProfileFromEasJson.js +0 -1
  126. package/build/credentials/manager/SelectIosDistributionTypeGraphqlFromBuildProfile.d.ts +3 -3
  127. package/build/credentials/manager/SelectPlatform.d.ts +3 -3
  128. package/build/devices/context.js +1 -1
  129. package/build/graphql/generated.d.ts +60 -1
  130. package/build/graphql/types/credentials/AndroidAppCredentials.js +6 -0
  131. package/build/project/android/applicationId.js +2 -2
  132. package/build/project/projectUtils.d.ts +4 -1
  133. package/build/project/projectUtils.js +13 -3
  134. package/build/project/publish.d.ts +3 -3
  135. package/build/project/publish.js +10 -10
  136. package/build/submit/android/AndroidSubmitCommand.js +3 -8
  137. package/build/submit/android/AndroidSubmitter.js +31 -9
  138. package/build/submit/android/ServiceAccountSource.d.ts +24 -5
  139. package/build/submit/android/ServiceAccountSource.js +54 -75
  140. package/build/submit/context.d.ts +14 -7
  141. package/build/submit/context.js +18 -4
  142. package/build/submit/ios/AppProduce.js +3 -3
  143. package/build/submit/ios/AppSpecificPasswordSource.js +1 -1
  144. package/build/submit/ios/IosSubmitCommand.js +1 -1
  145. package/build/utils/json.js +2 -6
  146. package/build/vcs/local.js +7 -7
  147. package/oclif.manifest.json +1 -1
  148. package/package.json +9 -8
@@ -1,8 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
- const fs_extra_1 = (0, tslib_1.__importDefault)(require("fs-extra"));
4
+ const chalk_1 = (0, tslib_1.__importDefault)(require("chalk"));
5
5
  const SubmissionMutation_1 = require("../../graphql/mutations/SubmissionMutation");
6
+ const formatFields_1 = (0, tslib_1.__importDefault)(require("../../utils/formatFields"));
6
7
  const ArchiveSource_1 = require("../ArchiveSource");
7
8
  const BaseSubmitter_1 = (0, tslib_1.__importDefault)(require("../BaseSubmitter"));
8
9
  const summary_1 = require("../utils/summary");
@@ -30,15 +31,14 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
30
31
  async resolveSourceOptionsAsync() {
31
32
  const androidPackage = await (0, AndroidPackageSource_1.getAndroidPackageAsync)(this.options.androidPackageSource);
32
33
  const archive = await (0, ArchiveSource_1.getArchiveAsync)(this.options.archiveSource);
33
- const serviceAccountPath = await (0, ServiceAccountSource_1.getServiceAccountAsync)(this.options.serviceAccountSource);
34
+ const serviceAccountKeyResult = await (0, ServiceAccountSource_1.getServiceAccountKeyResultAsync)(this.ctx, this.options.serviceAccountSource, androidPackage);
34
35
  return {
35
36
  androidPackage,
36
37
  archive,
37
- serviceAccountPath,
38
+ serviceAccountKeyResult,
38
39
  };
39
40
  }
40
- async formatSubmissionConfigAsync(options, { archive, androidPackage, serviceAccountPath }) {
41
- const serviceAccount = await fs_extra_1.default.readFile(serviceAccountPath, 'utf-8');
41
+ async formatSubmissionConfigAsync(options, { archive, androidPackage, serviceAccountKeyResult }) {
42
42
  const { track, releaseStatus, changesNotSentForReview } = options;
43
43
  return {
44
44
  applicationIdentifier: androidPackage,
@@ -46,10 +46,10 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
46
46
  track,
47
47
  changesNotSentForReview,
48
48
  releaseStatus,
49
- googleServiceAccountKeyJson: serviceAccount,
49
+ ...serviceAccountKeyResult.result,
50
50
  };
51
51
  }
52
- prepareSummaryData(options, { archive, androidPackage, serviceAccountPath }) {
52
+ prepareSummaryData(options, { archive, androidPackage, serviceAccountKeyResult }) {
53
53
  const { projectId, track, releaseStatus, changesNotSentForReview } = options;
54
54
  // structuring order affects table rows order
55
55
  return {
@@ -58,7 +58,7 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
58
58
  track,
59
59
  changesNotSentForReview: changesNotSentForReview !== null && changesNotSentForReview !== void 0 ? changesNotSentForReview : undefined,
60
60
  releaseStatus: releaseStatus !== null && releaseStatus !== void 0 ? releaseStatus : undefined,
61
- serviceAccountPath,
61
+ formattedServiceAccount: formatServiceAccountSummary(serviceAccountKeyResult),
62
62
  ...(0, summary_1.formatArchiveSourceSummary)(archive),
63
63
  };
64
64
  }
@@ -70,8 +70,30 @@ const SummaryHumanReadableKeys = {
70
70
  archiveUrl: 'Download URL',
71
71
  changesNotSentForReview: 'Changes not sent for a review',
72
72
  formattedBuild: 'Build',
73
+ formattedServiceAccount: 'Google Service Account Key',
73
74
  projectId: 'Project ID',
74
75
  releaseStatus: 'Release status',
75
- serviceAccountPath: 'Google Service Key',
76
76
  track: 'Release track',
77
77
  };
78
+ function formatServiceAccountSummary({ summary }) {
79
+ const { email: serviceAccountEmail, path: serviceAccountKeyPath, source: serviceAccountKeySource, } = summary;
80
+ const fields = [
81
+ {
82
+ label: 'Key Source',
83
+ value: serviceAccountKeySource,
84
+ },
85
+ {
86
+ label: 'Key Path',
87
+ value: serviceAccountKeyPath,
88
+ },
89
+ {
90
+ label: 'Account E-mail',
91
+ value: serviceAccountEmail,
92
+ },
93
+ ];
94
+ const filteredFields = fields.filter(({ value }) => value !== undefined && value !== null);
95
+ return ('\n' +
96
+ (0, formatFields_1.default)(filteredFields, {
97
+ labelFormat: label => ` ${chalk_1.default.dim(label)}:`,
98
+ }));
99
+ }
@@ -1,7 +1,9 @@
1
+ import { Platform } from '@expo/eas-build-job';
2
+ import { SubmissionContext } from '../context';
1
3
  export declare enum ServiceAccountSourceType {
2
4
  path = 0,
3
5
  prompt = 1,
4
- detect = 2
6
+ credentialsService = 2
5
7
  }
6
8
  interface ServiceAccountSourceBase {
7
9
  sourceType: ServiceAccountSourceType;
@@ -13,9 +15,26 @@ interface ServiceAccountPathSource extends ServiceAccountSourceBase {
13
15
  interface ServiceAccountPromptSource extends ServiceAccountSourceBase {
14
16
  sourceType: ServiceAccountSourceType.prompt;
15
17
  }
16
- interface ServiceAccountDetectSource extends ServiceAccountSourceBase {
17
- sourceType: ServiceAccountSourceType.detect;
18
+ export interface ServiceAccountCredentialsServiceSource extends ServiceAccountSourceBase {
19
+ sourceType: ServiceAccountSourceType.credentialsService;
18
20
  }
19
- export declare type ServiceAccountSource = ServiceAccountPathSource | ServiceAccountPromptSource | ServiceAccountDetectSource;
20
- export declare function getServiceAccountAsync(source: ServiceAccountSource): Promise<string>;
21
+ export declare type ServiceAccountKeyResult = {
22
+ result: ServiceAccountKeyFile | ServiceAccountKeyFromExpoServers;
23
+ summary: ServiceAccountKeySummary;
24
+ };
25
+ declare type ServiceAccountKeySummary = {
26
+ source: 'local' | 'EAS servers';
27
+ path?: string;
28
+ email: string;
29
+ };
30
+ declare type ServiceAccountKeyFile = {
31
+ googleServiceAccountKeyJson: string;
32
+ };
33
+ declare type ServiceAccountKeyFromExpoServers = {
34
+ googleServiceAccountKeyId: string;
35
+ };
36
+ export declare type ServiceAccountSource = ServiceAccountPathSource | ServiceAccountPromptSource | ServiceAccountCredentialsServiceSource;
37
+ export declare function getServiceAccountKeyResultAsync(ctx: SubmissionContext<Platform.ANDROID>, source: ServiceAccountSource, androidApplicationIdentifier: string): Promise<ServiceAccountKeyResult>;
38
+ export declare function getServiceAccountKeyPathAsync(source: ServiceAccountSource): Promise<string>;
39
+ export declare function getServiceAccountFromCredentialsServiceAsync(ctx: SubmissionContext<Platform.ANDROID>, androidApplicationIdentifier: string): Promise<ServiceAccountKeyResult>;
21
40
  export {};
@@ -1,67 +1,85 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getServiceAccountAsync = exports.ServiceAccountSourceType = void 0;
3
+ exports.getServiceAccountFromCredentialsServiceAsync = exports.getServiceAccountKeyPathAsync = exports.getServiceAccountKeyResultAsync = exports.ServiceAccountSourceType = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const chalk_1 = (0, tslib_1.__importDefault)(require("chalk"));
6
- const fast_glob_1 = (0, tslib_1.__importDefault)(require("fast-glob"));
7
6
  const fs_extra_1 = (0, tslib_1.__importDefault)(require("fs-extra"));
8
- const path_1 = (0, tslib_1.__importDefault)(require("path"));
7
+ const nullthrows_1 = (0, tslib_1.__importDefault)(require("nullthrows"));
8
+ const SetupGoogleServiceAccountKey_1 = require("../../credentials/android/actions/SetupGoogleServiceAccountKey");
9
+ const googleServiceAccountKey_1 = require("../../credentials/android/utils/googleServiceAccountKey");
9
10
  const log_1 = (0, tslib_1.__importStar)(require("../../log"));
10
- const projectUtils_1 = require("../../project/projectUtils");
11
11
  const prompts_1 = require("../../prompts");
12
- const filterAsync_1 = require("../../utils/filterAsync");
12
+ const Account_1 = require("../../user/Account");
13
13
  const files_1 = require("../utils/files");
14
14
  var ServiceAccountSourceType;
15
15
  (function (ServiceAccountSourceType) {
16
16
  ServiceAccountSourceType[ServiceAccountSourceType["path"] = 0] = "path";
17
17
  ServiceAccountSourceType[ServiceAccountSourceType["prompt"] = 1] = "prompt";
18
- ServiceAccountSourceType[ServiceAccountSourceType["detect"] = 2] = "detect";
19
- // credentialsService,
20
- // ...
18
+ ServiceAccountSourceType[ServiceAccountSourceType["credentialsService"] = 2] = "credentialsService";
21
19
  })(ServiceAccountSourceType = exports.ServiceAccountSourceType || (exports.ServiceAccountSourceType = {}));
22
- async function getServiceAccountAsync(source) {
20
+ async function getServiceAccountKeyResultAsync(ctx, source, androidApplicationIdentifier) {
21
+ if (source.sourceType === ServiceAccountSourceType.credentialsService) {
22
+ return await getServiceAccountFromCredentialsServiceAsync(ctx, androidApplicationIdentifier);
23
+ }
24
+ else {
25
+ return await getServiceAccountLocallyAsync(source);
26
+ }
27
+ }
28
+ exports.getServiceAccountKeyResultAsync = getServiceAccountKeyResultAsync;
29
+ async function getServiceAccountLocallyAsync(source) {
30
+ const serviceAccountKeyPath = await getServiceAccountKeyPathAsync(source);
31
+ const serviceAccountKey = (0, googleServiceAccountKey_1.readAndValidateServiceAccountKey)(serviceAccountKeyPath);
32
+ return {
33
+ result: { googleServiceAccountKeyJson: await fs_extra_1.default.readFile(serviceAccountKeyPath, 'utf-8') },
34
+ summary: {
35
+ source: 'local',
36
+ path: serviceAccountKeyPath,
37
+ email: serviceAccountKey.client_email,
38
+ },
39
+ };
40
+ }
41
+ async function getServiceAccountKeyPathAsync(source) {
23
42
  switch (source.sourceType) {
24
43
  case ServiceAccountSourceType.path:
25
44
  return await handlePathSourceAsync(source);
26
45
  case ServiceAccountSourceType.prompt:
27
46
  return await handlePromptSourceAsync(source);
28
- case ServiceAccountSourceType.detect:
29
- return await handleDetectSourceAsync(source);
47
+ case ServiceAccountSourceType.credentialsService: {
48
+ throw new Error(`ServiceAccountSource ${source} does not return a path.`);
49
+ }
30
50
  }
31
51
  }
32
- exports.getServiceAccountAsync = getServiceAccountAsync;
52
+ exports.getServiceAccountKeyPathAsync = getServiceAccountKeyPathAsync;
53
+ async function getServiceAccountFromCredentialsServiceAsync(ctx, androidApplicationIdentifier) {
54
+ const appLookupParams = {
55
+ account: (0, nullthrows_1.default)((0, Account_1.findAccountByName)(ctx.user.accounts, ctx.accountName), `You do not have access to account: ${ctx.accountName}`),
56
+ projectName: ctx.projectName,
57
+ androidApplicationIdentifier,
58
+ };
59
+ const setupGoogleServiceAccountKeyAction = new SetupGoogleServiceAccountKey_1.SetupGoogleServiceAccountKey(appLookupParams);
60
+ const androidAppCredentials = await setupGoogleServiceAccountKeyAction.runAsync(ctx.credentialsCtx);
61
+ const googleServiceAccountKey = (0, nullthrows_1.default)(androidAppCredentials.googleServiceAccountKeyForSubmissions, 'Credentials Service must provide a valid GoogleServiceAccountKey');
62
+ return {
63
+ result: {
64
+ googleServiceAccountKeyId: googleServiceAccountKey.id,
65
+ },
66
+ summary: {
67
+ source: 'EAS servers',
68
+ email: googleServiceAccountKey.clientEmail,
69
+ },
70
+ };
71
+ }
72
+ exports.getServiceAccountFromCredentialsServiceAsync = getServiceAccountFromCredentialsServiceAsync;
33
73
  async function handlePathSourceAsync(source) {
34
74
  if (!(await (0, files_1.isExistingFileAsync)(source.path))) {
35
75
  log_1.default.warn(`File ${source.path} doesn't exist.`);
36
- return await getServiceAccountAsync({ sourceType: ServiceAccountSourceType.prompt });
76
+ return await getServiceAccountKeyPathAsync({ sourceType: ServiceAccountSourceType.prompt });
37
77
  }
38
78
  return source.path;
39
79
  }
40
- async function handleDetectSourceAsync(_source) {
41
- var _a;
42
- const projectDir = (_a = (await (0, projectUtils_1.findProjectRootAsync)())) !== null && _a !== void 0 ? _a : process.cwd();
43
- const foundFilePaths = await (0, fast_glob_1.default)('**/*.json', {
44
- cwd: projectDir,
45
- ignore: ['app.json', 'package*.json', 'tsconfig.json', 'node_modules'],
46
- });
47
- const googleServiceFiles = await (0, filterAsync_1.filterAsync)(foundFilePaths.map(file => path_1.default.join(projectDir, file)), fileIsGoogleServicesAsync);
48
- if (googleServiceFiles.length > 1) {
49
- const selectedPath = await displayPathChooserAsync(googleServiceFiles, projectDir);
50
- if (selectedPath !== false) {
51
- return selectedPath;
52
- }
53
- }
54
- else if (googleServiceFiles.length === 1) {
55
- const [detectedPath] = googleServiceFiles;
56
- if (await confirmDetectedPathAsync(detectedPath)) {
57
- return detectedPath;
58
- }
59
- }
60
- return await getServiceAccountAsync({ sourceType: ServiceAccountSourceType.prompt });
61
- }
62
80
  async function handlePromptSourceAsync(_source) {
63
81
  const path = await askForServiceAccountPathAsync();
64
- return await getServiceAccountAsync({
82
+ return await getServiceAccountKeyPathAsync({
65
83
  sourceType: ServiceAccountSourceType.path,
66
84
  path,
67
85
  });
@@ -90,42 +108,3 @@ async function askForServiceAccountPathAsync() {
90
108
  });
91
109
  return filePath;
92
110
  }
93
- async function displayPathChooserAsync(paths, projectDir) {
94
- const choices = paths.map(f => ({
95
- value: f,
96
- title: f.startsWith(projectDir) ? path_1.default.relative(projectDir, f) : f,
97
- }));
98
- choices.push({
99
- title: 'None of the above',
100
- value: false,
101
- });
102
- log_1.default.log('Multiple Google Service Account JSON keys have been found inside your project directory.');
103
- const { selectedPath } = await (0, prompts_1.promptAsync)({
104
- name: 'selectedPath',
105
- type: 'select',
106
- message: 'Choose the key you want to use for this submission:',
107
- choices,
108
- });
109
- log_1.default.addNewLineIfNone();
110
- return selectedPath;
111
- }
112
- async function confirmDetectedPathAsync(path) {
113
- log_1.default.log(`A Google Service Account JSON key has been found at\n ${chalk_1.default.underline(path)}`);
114
- const { confirmed } = await (0, prompts_1.promptAsync)({
115
- name: 'confirmed',
116
- type: 'confirm',
117
- message: 'Would you like to use this file?',
118
- initial: true,
119
- });
120
- log_1.default.addNewLineIfNone();
121
- return confirmed;
122
- }
123
- async function fileIsGoogleServicesAsync(path) {
124
- try {
125
- const jsonFile = await fs_extra_1.default.readJson(path);
126
- return jsonFile.type === 'service_account';
127
- }
128
- catch (e) {
129
- return false;
130
- }
131
- }
@@ -1,14 +1,20 @@
1
1
  import { ExpoConfig } from '@expo/config';
2
2
  import { Platform } from '@expo/eas-build-job';
3
3
  import { SubmitProfile } from '@expo/eas-json';
4
+ import { CredentialsContext } from '../credentials/context';
5
+ import { Actor } from '../user/User';
4
6
  export interface SubmissionContext<T extends Platform> {
7
+ accountName: string;
5
8
  archiveFlags: SubmitArchiveFlags;
9
+ credentialsCtx: CredentialsContext;
10
+ exp: ExpoConfig;
11
+ nonInteractive: boolean;
6
12
  platform: T;
7
13
  profile: SubmitProfile<T>;
8
14
  projectDir: string;
9
15
  projectId: string;
10
- nonInteractive: boolean;
11
- exp: ExpoConfig;
16
+ projectName: string;
17
+ user: Actor;
12
18
  }
13
19
  export interface SubmitArchiveFlags {
14
20
  latest?: boolean;
@@ -16,12 +22,13 @@ export interface SubmitArchiveFlags {
16
22
  path?: string;
17
23
  url?: string;
18
24
  }
19
- export declare function createSubmissionContext<T extends Platform>(params: {
20
- platform: T;
25
+ export declare function createSubmissionContextAsync<T extends Platform>(params: {
21
26
  archiveFlags: SubmitArchiveFlags;
27
+ credentialsCtx?: CredentialsContext;
28
+ env?: Record<string, string>;
29
+ nonInteractive: boolean;
30
+ platform: T;
22
31
  profile: SubmitProfile<T>;
23
32
  projectDir: string;
24
33
  projectId: string;
25
- nonInteractive: boolean;
26
- env?: Record<string, string>;
27
- }): SubmissionContext<T>;
34
+ }): Promise<SubmissionContext<T>>;
@@ -1,14 +1,28 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.createSubmissionContext = void 0;
3
+ exports.createSubmissionContextAsync = void 0;
4
+ const context_1 = require("../credentials/context");
4
5
  const expoConfig_1 = require("../project/expoConfig");
5
- function createSubmissionContext(params) {
6
- const { projectDir } = params;
6
+ const projectUtils_1 = require("../project/projectUtils");
7
+ const actions_1 = require("../user/actions");
8
+ async function createSubmissionContextAsync(params) {
9
+ const { projectDir, nonInteractive } = params;
7
10
  const exp = (0, expoConfig_1.getExpoConfig)(projectDir, { env: params.env });
8
11
  const { env, ...rest } = params;
12
+ const user = await (0, actions_1.ensureLoggedInAsync)();
13
+ const projectName = exp.slug;
14
+ const accountName = (0, projectUtils_1.getProjectAccountName)(exp, user);
15
+ let credentialsCtx = params.credentialsCtx;
16
+ if (!credentialsCtx) {
17
+ credentialsCtx = new context_1.CredentialsContext({ projectDir, user, exp, nonInteractive });
18
+ }
9
19
  return {
10
20
  ...rest,
21
+ accountName,
22
+ credentialsCtx,
11
23
  exp,
24
+ projectName,
25
+ user,
12
26
  };
13
27
  }
14
- exports.createSubmissionContext = createSubmissionContext;
28
+ exports.createSubmissionContextAsync = createSubmissionContextAsync;
@@ -20,7 +20,7 @@ async function ensureAppStoreConnectAppExistsAsync(ctx) {
20
20
  appName: (_a = appName !== null && appName !== void 0 ? appName : exp.name) !== null && _a !== void 0 ? _a : (await promptForAppNameAsync()),
21
21
  language: (0, language_1.sanitizeLanguage)(language),
22
22
  };
23
- return await createAppStoreConnectAppAsync(options);
23
+ return await createAppStoreConnectAppAsync(ctx, options);
24
24
  }
25
25
  exports.ensureAppStoreConnectAppExistsAsync = ensureAppStoreConnectAppExistsAsync;
26
26
  async function isProvisioningAvailableAsync(requestCtx) {
@@ -30,9 +30,9 @@ async function isProvisioningAvailableAsync(requestCtx) {
30
30
  const [user] = await apple_utils_1.User.getAsync(requestCtx, { query: { filter: { username } } });
31
31
  return user.attributes.provisioningAllowed;
32
32
  }
33
- async function createAppStoreConnectAppAsync(options) {
33
+ async function createAppStoreConnectAppAsync(ctx, options) {
34
34
  const { appleId, appleTeamId, bundleIdentifier: bundleId, appName, language, companyName, sku, } = options;
35
- const authCtx = await (0, authenticate_1.authenticateAsync)({
35
+ const authCtx = await ctx.credentialsCtx.appStore.ensureAuthenticatedAsync({
36
36
  appleId,
37
37
  teamId: appleTeamId,
38
38
  });
@@ -18,7 +18,7 @@ async function getAppSpecificPasswordAsync(source) {
18
18
  }
19
19
  else if (source.sourceType === AppSpecificPasswordSourceType.prompt) {
20
20
  log_1.default.addNewLineIfNone();
21
- log_1.default.log((0, wrap_ansi_1.default)(`Please enter your Apple app-specific password. You can also provide it by using ${chalk_1.default.italic('EXPO_APPLE_APP_SPECIFIC_PASSWORD')} env variable.`, process.stdout.columns || 80));
21
+ log_1.default.log((0, wrap_ansi_1.default)(`Please enter your Apple app-specific password. You can also provide it by using the ${chalk_1.default.bold('EXPO_APPLE_APP_SPECIFIC_PASSWORD')} environment variable.`, process.stdout.columns || 80));
22
22
  log_1.default.log((0, log_1.learnMore)('https://expo.fyi/apple-app-specific-password'));
23
23
  const { appSpecificPassword } = await (0, prompts_1.promptAsync)({
24
24
  name: 'appSpecificPassword',
@@ -81,7 +81,7 @@ class IosSubmitCommand {
81
81
  return (0, results_1.result)(new Error('Set ascAppId in the submit profile (eas.json).'));
82
82
  }
83
83
  else {
84
- log_1.default.log((0, wrap_ansi_1.default)(chalk_1.default.italic(`Ensuring your app exists on App Store Connect. This step can be skipped by providing ascAppId in the submit profile. ${(0, log_1.learnMore)('https://expo.fyi/asc-app-id')}`), process.stdout.columns || 80));
84
+ log_1.default.log((0, wrap_ansi_1.default)(`Ensuring your app exists on App Store Connect. This step can be skipped by providing ${chalk_1.default.bold(`ascAppId`)} in the submit profile. ${(0, log_1.learnMore)('https://expo.fyi/asc-app-id')}`, process.stdout.columns || 80));
85
85
  log_1.default.addNewLineIfNone();
86
86
  try {
87
87
  const { ascAppIdentifier } = await (0, AppProduce_1.ensureAppStoreConnectAppExistsAsync)(this.ctx);
@@ -10,9 +10,7 @@ function enableJsonOutput() {
10
10
  return;
11
11
  }
12
12
  stdoutWrite = process.stdout.write;
13
- process.stdout.write = (...args) => {
14
- return process.stderr.write.call(null, args);
15
- };
13
+ process.stdout.write = process.stderr.write.bind(process.stderr);
16
14
  }
17
15
  exports.enableJsonOutput = enableJsonOutput;
18
16
  function printJsonOnlyOutput(value) {
@@ -22,9 +20,7 @@ function printJsonOnlyOutput(value) {
22
20
  log_1.default.log(JSON.stringify(sanitizeValue(value), null, 2));
23
21
  }
24
22
  finally {
25
- process.stdout.write = (...args) => {
26
- return process.stderr.write.call(null, args);
27
- };
23
+ process.stdout.write = process.stderr.write.bind(process.stderr);
28
24
  }
29
25
  }
30
26
  exports.printJsonOnlyOutput = printJsonOnlyOutput;
@@ -14,7 +14,7 @@ class LocalClient extends vcs_1.Client {
14
14
  }
15
15
  async makeShallowCopyAsync(destinationPath) {
16
16
  const srcPath = getRootPath();
17
- const ignore = initIgnore();
17
+ const ignore = await initIgnoreAsync();
18
18
  await fs_extra_1.default.copy(srcPath, destinationPath, {
19
19
  filter: (srcFilePath) => {
20
20
  if (srcFilePath === srcPath) {
@@ -25,7 +25,7 @@ class LocalClient extends vcs_1.Client {
25
25
  });
26
26
  }
27
27
  async isFileIgnoredAsync(filePath) {
28
- return initIgnore().ignores(filePath);
28
+ return (await initIgnoreAsync()).ignores(filePath);
29
29
  }
30
30
  }
31
31
  exports.default = LocalClient;
@@ -37,16 +37,16 @@ function getRootPath() {
37
37
  }
38
38
  return rootPath;
39
39
  }
40
- function initIgnore() {
40
+ async function initIgnoreAsync() {
41
41
  const srcPath = getRootPath();
42
42
  const easIgnorePath = path_1.default.join(srcPath, '.easignore');
43
43
  const gitIgnorePath = path_1.default.join(srcPath, '.gitignore');
44
44
  let ignoreFile = DEFAULT_IGNORE;
45
- if (fs_extra_1.default.pathExistsSync(easIgnorePath)) {
46
- ignoreFile = fs_extra_1.default.readFileSync(easIgnorePath, 'utf8');
45
+ if (await fs_extra_1.default.pathExists(easIgnorePath)) {
46
+ ignoreFile = await fs_extra_1.default.readFile(easIgnorePath, 'utf8');
47
47
  }
48
- else if (fs_extra_1.default.pathExistsSync(gitIgnorePath)) {
49
- ignoreFile = fs_extra_1.default.readFileSync(gitIgnorePath, 'utf8');
48
+ else if (await fs_extra_1.default.pathExists(gitIgnorePath)) {
49
+ ignoreFile = await fs_extra_1.default.readFile(gitIgnorePath, 'utf8');
50
50
  }
51
51
  return (0, ignore_1.default)().add(ignoreFile);
52
52
  }
@@ -1 +1 @@
1
- {"version":"0.29.0","commands":{"analytics":{"id":"analytics","description":"view or change analytics settings","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"STATUS","options":["on","off"]}]},"config":{"id":"config","description":"show the eas.json config","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios)","options":["android","ios"]},"profile":{"name":"profile","type":"option"}},"args":[]},"credentials":{"id":"credentials","description":"manage your credentials","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"diagnostics":{"id":"diagnostics","description":"log environment info to the console","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"submit":{"id":"submit","description":"submit build archive to app store\nSee how to configure submits with eas.json: \u001b[2m\u001b[4mhttps://docs.expo.dev/submit/eas-json/\u001b[24m\u001b[22m","pluginName":"eas-cli","pluginType":"core","aliases":["build:submit"],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios|all)","options":["android","ios","all"]},"profile":{"name":"profile","type":"option","description":"Name of the submit profile from eas.json. Defaults to \"release\" if defined in eas.json."},"latest":{"name":"latest","type":"boolean","description":"Submit the latest build for specified platform","allowNo":false},"id":{"name":"id","type":"option","description":"ID of the build to submit"},"path":{"name":"path","type":"option","description":"Path to the .apk/.aab/.ipa file"},"url":{"name":"url","type":"option","description":"App archive url"},"verbose":{"name":"verbose","type":"boolean","description":"Always print logs from Submission Service","allowNo":false},"wait":{"name":"wait","type":"boolean","description":"Wait for submission to complete","allowNo":true},"non-interactive":{"name":"non-interactive","type":"boolean","description":"Run command in non-interactive mode","allowNo":false}},"args":[]},"account:login":{"id":"account:login","description":"log in with your Expo account","pluginName":"eas-cli","pluginType":"core","aliases":["login"],"flags":{},"args":[]},"account:logout":{"id":"account:logout","description":"log out","pluginName":"eas-cli","pluginType":"core","aliases":["logout"],"flags":{},"args":[]},"account:view":{"id":"account:view","description":"show the username you are logged in as","pluginName":"eas-cli","pluginType":"core","aliases":["whoami"],"flags":{},"args":[]},"branch:create":{"id":"branch:create","description":"Create a branch on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return a json with the new branch ID and name.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to create","required":false}]},"branch:delete":{"id":"branch:delete","description":"Republish an update group","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return JSON with the edited branch's ID and name.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to delete","required":false}]},"branch:list":{"id":"branch:list","description":"List all branches on this project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return output as JSON","allowNo":false}},"args":[]},"branch:publish":{"id":"branch:publish","description":"Publish an update group to a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"message":{"name":"message","type":"option","description":"short message describing the updates.","required":false},"republish":{"name":"republish","type":"boolean","description":"republish an update group","allowNo":false},"group":{"name":"group","type":"option","description":"update group to republish"},"input-dir":{"name":"input-dir","type":"option","description":"location of the bundle","required":false,"default":"dist"},"skip-bundler":{"name":"skip-bundler","type":"boolean","description":"skip running Expo CLI to bundle the app before publishing","allowNo":false},"platform":{"name":"platform","type":"option","char":"p","description":"only publish to a single platform","required":false,"helpValue":"(android|ios|all)","options":["android","ios","all"],"default":"all"},"json":{"name":"json","type":"boolean","description":"return a json with the new update group.","allowNo":false},"auto":{"name":"auto","type":"boolean","description":"use the current git branch and commit message for the EAS branch and update message","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to publish on"}]},"branch:rename":{"id":"branch:rename","description":"Rename a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"from":{"name":"from","type":"option","description":"current name of the branch.","required":false},"to":{"name":"to","type":"option","description":"new name of the branch.","required":false},"json":{"name":"json","type":"boolean","description":"return a json with the edited branch's ID and name.","allowNo":false}},"args":[]},"branch:view":{"id":"branch:view","description":"View a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return a json with the branch's ID name and recent update groups.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to view","required":false}]},"build:cancel":{"id":"build:cancel","description":"Cancel a build.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"BUILD_ID"}]},"build:configure":{"id":"build:configure","description":"Configure the project to support EAS Build.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","description":"Platform to configure","helpValue":"(android|ios|all)","options":["android","ios","all"]}},"args":[]},"build":{"id":"build","description":"start a build","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios|all)","options":["android","ios","all"]},"skip-credentials-check":{"name":"skip-credentials-check","type":"boolean","hidden":true,"allowNo":false},"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false},"skip-project-configuration":{"name":"skip-project-configuration","type":"boolean","description":"Skip project configuration","allowNo":false},"profile":{"name":"profile","type":"option","description":"Name of the build profile from eas.json","helpValue":"PROFILE_NAME","default":"release"},"non-interactive":{"name":"non-interactive","type":"boolean","description":"Run command in non-interactive mode","allowNo":false},"local":{"name":"local","type":"boolean","description":"Run build locally [experimental]","allowNo":false},"wait":{"name":"wait","type":"boolean","description":"Wait for build(s) to complete","allowNo":true},"clear-cache":{"name":"clear-cache","type":"boolean","description":"Clear cache before the build","allowNo":false},"auto-submit":{"name":"auto-submit","type":"boolean","description":"Submit on build complete using the submit profile with the same name as the build profile","allowNo":false},"auto-submit-with-profile":{"name":"auto-submit-with-profile","type":"option","description":"Submit on build complete using the submit profile with provided name","helpValue":"PROFILE_NAME"}},"args":[]},"build:list":{"id":"build:list","description":"list all builds for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","helpValue":"(all|android|ios)","options":["all","android","ios"]},"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false},"status":{"name":"status","type":"option","helpValue":"(new|in-queue|in-progress|errored|finished|canceled)","options":["new","in-queue","in-progress","errored","finished","canceled"]},"distribution":{"name":"distribution","type":"option","helpValue":"(store|internal|simulator)","options":["store","internal","simulator"]},"channel":{"name":"channel","type":"option"},"appVersion":{"name":"appVersion","type":"option"},"appBuildVersion":{"name":"appBuildVersion","type":"option"},"sdkVersion":{"name":"sdkVersion","type":"option"},"runtimeVersion":{"name":"runtimeVersion","type":"option"},"appIdentifier":{"name":"appIdentifier","type":"option"},"buildProfile":{"name":"buildProfile","type":"option"},"gitCommitHash":{"name":"gitCommitHash","type":"option"},"limit":{"name":"limit","type":"option"}},"args":[]},"build:view":{"id":"build:view","description":"view a build for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false}},"args":[{"name":"BUILD_ID"}]},"channel:create":{"id":"channel:create","description":"Create a channel on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the new channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to create","required":false}]},"channel:edit":{"id":"channel:edit","description":"Point a channel at a new branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"branch":{"name":"branch","type":"option","description":"Name of the branch to point to"},"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to edit","required":false}]},"channel:list":{"id":"channel:list","description":"List all channels on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[]},"channel:rollout":{"id":"channel:rollout","description":"Rollout a new branch out to a channel incrementally.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"branch":{"name":"branch","type":"option","description":"branch to rollout","required":false},"percent":{"name":"percent","type":"option","description":"percent of traffic to redirect to the new branch","required":false},"end":{"name":"end","type":"boolean","description":"end the rollout","allowNo":false},"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the new channel ID, name and branch mapping","allowNo":false}},"args":[{"name":"channel","description":"rollout that the channel is on","required":true}]},"channel:view":{"id":"channel:view","description":"View a channel on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to view","required":false}]},"device:create":{"id":"device:create","description":"register new Apple Devices to use for internal distribution","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"device:list":{"id":"device:list","description":"list all registered devices for your account","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"apple-team-id":{"name":"apple-team-id","type":"option"}},"args":[]},"device:view":{"id":"device:view","description":"view a device for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"UDID"}]},"project:info":{"id":"project:info","description":"information about the current project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"project:init":{"id":"project:init","description":"create or link an EAS project","pluginName":"eas-cli","pluginType":"core","aliases":["init"],"flags":{},"args":[]},"secret:create":{"id":"secret:create","description":"Create an environment secret on the current project or owner account.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"scope":{"name":"scope","type":"option","description":"Scope for the secret","helpValue":"(account|project)","options":["account","project"],"default":"project"},"name":{"name":"name","type":"option","description":"Name of the secret"},"value":{"name":"value","type":"option","description":"Value of the secret"},"force":{"name":"force","type":"boolean","description":"Delete and recreate existing secrets","allowNo":false}},"args":[]},"secret:delete":{"id":"secret:delete","description":"Delete an environment secret by ID.\nUnsure where to find the secret's ID? Run \u001b[1meas secrets:list\u001b[22m","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"id":{"name":"id","type":"option","description":"ID of the secret to delete"}},"args":[]},"secret:list":{"id":"secret:list","description":"Lists environment secrets available for your current app","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"update:delete":{"id":"update:delete","description":"Delete all the updates in an update Group.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Return a json with the group ID of the deleted updates.","allowNo":false}},"args":[{"name":"groupId","description":"The ID of an update group to delete.","required":true}]},"update:view":{"id":"update:view","description":"Update group details.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Return a json with the updates belonging to the group.","allowNo":false}},"args":[{"name":"groupId","description":"The ID of an update group.","required":true}]},"webhook:create":{"id":"webhook:create","description":"Create a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"],"default":"BUILD"},"url":{"name":"url","type":"option","description":"Webhook URL"},"secret":{"name":"secret","type":"option","description":"Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header."}},"args":[]},"webhook:delete":{"id":"webhook:delete","description":"Delete a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"ID","description":"ID of the webhook to delete","required":false}]},"webhook:list":{"id":"webhook:list","description":"List webhooks on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"]}},"args":[]},"webhook:update":{"id":"webhook:update","description":"Create a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"id":{"name":"id","type":"option","description":"Webhook ID","required":true},"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"],"default":"BUILD"},"url":{"name":"url","type":"option","description":"Webhook URL"},"secret":{"name":"secret","type":"option","description":"Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header."}},"args":[]},"webhook:view":{"id":"webhook:view","description":"View a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"ID","description":"ID of the webhook to view","required":true}]}}}
1
+ {"version":"0.31.0","commands":{"analytics":{"id":"analytics","description":"view or change analytics settings","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"STATUS","options":["on","off"]}]},"config":{"id":"config","description":"show the eas.json config","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios)","options":["android","ios"]},"profile":{"name":"profile","type":"option"}},"args":[]},"credentials":{"id":"credentials","description":"manage your credentials","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"diagnostics":{"id":"diagnostics","description":"log environment info to the console","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"submit":{"id":"submit","description":"submit build archive to app store\nSee how to configure submits with eas.json: https://docs.expo.dev/submit/eas-json/","pluginName":"eas-cli","pluginType":"core","aliases":["build:submit"],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios|all)","options":["android","ios","all"]},"profile":{"name":"profile","type":"option","description":"Name of the submit profile from eas.json. Defaults to \"release\" if defined in eas.json."},"latest":{"name":"latest","type":"boolean","description":"Submit the latest build for specified platform","allowNo":false},"id":{"name":"id","type":"option","description":"ID of the build to submit"},"path":{"name":"path","type":"option","description":"Path to the .apk/.aab/.ipa file"},"url":{"name":"url","type":"option","description":"App archive url"},"verbose":{"name":"verbose","type":"boolean","description":"Always print logs from Submission Service","allowNo":false},"wait":{"name":"wait","type":"boolean","description":"Wait for submission to complete","allowNo":true},"non-interactive":{"name":"non-interactive","type":"boolean","description":"Run command in non-interactive mode","allowNo":false}},"args":[]},"account:login":{"id":"account:login","description":"log in with your Expo account","pluginName":"eas-cli","pluginType":"core","aliases":["login"],"flags":{},"args":[]},"account:logout":{"id":"account:logout","description":"log out","pluginName":"eas-cli","pluginType":"core","aliases":["logout"],"flags":{},"args":[]},"account:view":{"id":"account:view","description":"show the username you are logged in as","pluginName":"eas-cli","pluginType":"core","aliases":["whoami"],"flags":{},"args":[]},"branch:create":{"id":"branch:create","description":"Create a branch on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return a json with the new branch ID and name.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to create","required":false}]},"branch:delete":{"id":"branch:delete","description":"Republish an update group","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return JSON with the edited branch's ID and name.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to delete","required":false}]},"branch:list":{"id":"branch:list","description":"List all branches on this project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return output as JSON","allowNo":false}},"args":[]},"branch:publish":{"id":"branch:publish","description":"Publish an update group to a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"message":{"name":"message","type":"option","description":"short message describing the updates.","required":false},"republish":{"name":"republish","type":"boolean","description":"republish an update group","allowNo":false},"group":{"name":"group","type":"option","description":"update group to republish"},"input-dir":{"name":"input-dir","type":"option","description":"location of the bundle","required":false,"default":"dist"},"skip-bundler":{"name":"skip-bundler","type":"boolean","description":"skip running Expo CLI to bundle the app before publishing","allowNo":false},"platform":{"name":"platform","type":"option","char":"p","description":"only publish to a single platform","required":false,"helpValue":"(android|ios|all)","options":["android","ios","all"],"default":"all"},"json":{"name":"json","type":"boolean","description":"return a json with the new update group.","allowNo":false},"auto":{"name":"auto","type":"boolean","description":"use the current git branch and commit message for the EAS branch and update message","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to publish on"}]},"branch:rename":{"id":"branch:rename","description":"Rename a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"from":{"name":"from","type":"option","description":"current name of the branch.","required":false},"to":{"name":"to","type":"option","description":"new name of the branch.","required":false},"json":{"name":"json","type":"boolean","description":"return a json with the edited branch's ID and name.","allowNo":false}},"args":[]},"branch:view":{"id":"branch:view","description":"View a branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"return a json with the branch's ID name and recent update groups.","allowNo":false}},"args":[{"name":"name","description":"Name of the branch to view","required":false}]},"build:cancel":{"id":"build:cancel","description":"Cancel a build.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"BUILD_ID"}]},"build:configure":{"id":"build:configure","description":"Configure the project to support EAS Build.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","description":"Platform to configure","helpValue":"(android|ios|all)","options":["android","ios","all"]}},"args":[]},"build":{"id":"build","description":"start a build","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","char":"p","helpValue":"(android|ios|all)","options":["android","ios","all"]},"skip-credentials-check":{"name":"skip-credentials-check","type":"boolean","hidden":true,"allowNo":false},"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false},"skip-project-configuration":{"name":"skip-project-configuration","type":"boolean","description":"Skip project configuration","allowNo":false},"profile":{"name":"profile","type":"option","description":"Name of the build profile from eas.json","helpValue":"PROFILE_NAME","default":"release"},"non-interactive":{"name":"non-interactive","type":"boolean","description":"Run command in non-interactive mode","allowNo":false},"local":{"name":"local","type":"boolean","description":"Run build locally [experimental]","allowNo":false},"wait":{"name":"wait","type":"boolean","description":"Wait for build(s) to complete","allowNo":true},"clear-cache":{"name":"clear-cache","type":"boolean","description":"Clear cache before the build","allowNo":false},"auto-submit":{"name":"auto-submit","type":"boolean","description":"Submit on build complete using the submit profile with the same name as the build profile","allowNo":false},"auto-submit-with-profile":{"name":"auto-submit-with-profile","type":"option","description":"Submit on build complete using the submit profile with provided name","helpValue":"PROFILE_NAME"}},"args":[]},"build:list":{"id":"build:list","description":"list all builds for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"platform":{"name":"platform","type":"option","helpValue":"(all|android|ios)","options":["all","android","ios"]},"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false},"status":{"name":"status","type":"option","helpValue":"(new|in-queue|in-progress|errored|finished|canceled)","options":["new","in-queue","in-progress","errored","finished","canceled"]},"distribution":{"name":"distribution","type":"option","helpValue":"(store|internal|simulator)","options":["store","internal","simulator"]},"channel":{"name":"channel","type":"option"},"appVersion":{"name":"appVersion","type":"option"},"appBuildVersion":{"name":"appBuildVersion","type":"option"},"sdkVersion":{"name":"sdkVersion","type":"option"},"runtimeVersion":{"name":"runtimeVersion","type":"option"},"appIdentifier":{"name":"appIdentifier","type":"option"},"buildProfile":{"name":"buildProfile","type":"option"},"gitCommitHash":{"name":"gitCommitHash","type":"option"},"limit":{"name":"limit","type":"option"}},"args":[]},"build:view":{"id":"build:view","description":"view a build for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Enable JSON output, non-JSON messages will be printed to stderr","allowNo":false}},"args":[{"name":"BUILD_ID"}]},"channel:create":{"id":"channel:create","description":"Create a channel on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the new channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to create","required":false}]},"channel:edit":{"id":"channel:edit","description":"Point a channel at a new branch.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"branch":{"name":"branch","type":"option","description":"Name of the branch to point to"},"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to edit","required":false}]},"channel:list":{"id":"channel:list","description":"List all channels on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[]},"channel:rollout":{"id":"channel:rollout","description":"Rollout a new branch out to a channel incrementally.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"branch":{"name":"branch","type":"option","description":"branch to rollout","required":false},"percent":{"name":"percent","type":"option","description":"percent of traffic to redirect to the new branch","required":false},"end":{"name":"end","type":"boolean","description":"end the rollout","allowNo":false},"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the new channel ID, name and branch mapping","allowNo":false}},"args":[{"name":"channel","description":"rollout that the channel is on","required":true}]},"channel:view":{"id":"channel:view","description":"View a channel on the current project.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"print output as a JSON object with the channel ID, name and branch mapping.","allowNo":false}},"args":[{"name":"name","description":"Name of the channel to view","required":false}]},"device:create":{"id":"device:create","description":"register new Apple Devices to use for internal distribution","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"device:list":{"id":"device:list","description":"list all registered devices for your account","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"apple-team-id":{"name":"apple-team-id","type":"option"}},"args":[]},"device:view":{"id":"device:view","description":"view a device for your project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"UDID"}]},"project:info":{"id":"project:info","description":"information about the current project","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"project:init":{"id":"project:init","description":"create or link an EAS project","pluginName":"eas-cli","pluginType":"core","aliases":["init"],"flags":{},"args":[]},"secret:create":{"id":"secret:create","description":"Create an environment secret on the current project or owner account.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"scope":{"name":"scope","type":"option","description":"Scope for the secret","helpValue":"(account|project)","options":["account","project"],"default":"project"},"name":{"name":"name","type":"option","description":"Name of the secret"},"value":{"name":"value","type":"option","description":"Value of the secret"},"force":{"name":"force","type":"boolean","description":"Delete and recreate existing secrets","allowNo":false}},"args":[]},"secret:delete":{"id":"secret:delete","description":"Delete an environment secret by ID.\nUnsure where to find the secret's ID? Run eas secrets:list","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"id":{"name":"id","type":"option","description":"ID of the secret to delete"}},"args":[]},"secret:list":{"id":"secret:list","description":"Lists environment secrets available for your current app","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"update:delete":{"id":"update:delete","description":"Delete all the updates in an update Group.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Return a json with the group ID of the deleted updates.","allowNo":false}},"args":[{"name":"groupId","description":"The ID of an update group to delete.","required":true}]},"update:view":{"id":"update:view","description":"Update group details.","pluginName":"eas-cli","pluginType":"core","hidden":true,"aliases":[],"flags":{"json":{"name":"json","type":"boolean","description":"Return a json with the updates belonging to the group.","allowNo":false}},"args":[{"name":"groupId","description":"The ID of an update group.","required":true}]},"webhook:create":{"id":"webhook:create","description":"Create a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"],"default":"BUILD"},"url":{"name":"url","type":"option","description":"Webhook URL"},"secret":{"name":"secret","type":"option","description":"Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header."}},"args":[]},"webhook:delete":{"id":"webhook:delete","description":"Delete a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"ID","description":"ID of the webhook to delete","required":false}]},"webhook:list":{"id":"webhook:list","description":"List webhooks on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"]}},"args":[]},"webhook:update":{"id":"webhook:update","description":"Create a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{"id":{"name":"id","type":"option","description":"Webhook ID","required":true},"event":{"name":"event","type":"option","description":"Event type that triggers the webhook","helpValue":"(BUILD)","options":["BUILD"],"default":"BUILD"},"url":{"name":"url","type":"option","description":"Webhook URL"},"secret":{"name":"secret","type":"option","description":"Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header."}},"args":[]},"webhook:view":{"id":"webhook:view","description":"View a webhook on the current project.","pluginName":"eas-cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"ID","description":"ID of the webhook to view","required":true}]}}}