eas-cli 13.4.2 → 14.0.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 (203) hide show
  1. package/README.md +73 -73
  2. package/build/ApiV2Error.js +5 -1
  3. package/build/analytics/AnalyticsManager.js +5 -4
  4. package/build/api.js +1 -0
  5. package/build/branch/actions/SelectBranch.js +1 -0
  6. package/build/branch/queries.d.ts +3 -3
  7. package/build/branch/queries.js +7 -5
  8. package/build/build/validate.js +6 -3
  9. package/build/channel/actions/SelectChannel.js +1 -0
  10. package/build/channel/queries.d.ts +0 -1
  11. package/build/channel/queries.js +11 -16
  12. package/build/commandUtils/EasCommand.js +100 -90
  13. package/build/commandUtils/builds.d.ts +1 -0
  14. package/build/commandUtils/builds.js +3 -0
  15. package/build/commandUtils/gating/FeatureGateEnvOverrides.js +1 -1
  16. package/build/commandUtils/gating/FeatureGating.js +2 -0
  17. package/build/commands/account/login.js +16 -18
  18. package/build/commands/account/logout.js +6 -8
  19. package/build/commands/account/view.js +8 -10
  20. package/build/commands/analytics.js +2 -2
  21. package/build/commands/branch/create.js +18 -20
  22. package/build/commands/branch/delete.js +17 -19
  23. package/build/commands/branch/list.js +11 -13
  24. package/build/commands/branch/publish.js +2 -2
  25. package/build/commands/branch/rename.js +18 -20
  26. package/build/commands/branch/view.js +19 -21
  27. package/build/commands/build/cancel.js +22 -24
  28. package/build/commands/build/configure.js +15 -17
  29. package/build/commands/build/delete.js +22 -24
  30. package/build/commands/build/index.js +81 -83
  31. package/build/commands/build/inspect.js +42 -44
  32. package/build/commands/build/internal.js +32 -34
  33. package/build/commands/build/list.js +58 -60
  34. package/build/commands/build/resign.js +36 -38
  35. package/build/commands/build/run.js +36 -38
  36. package/build/commands/build/version/get.js +21 -23
  37. package/build/commands/build/version/set.js +20 -22
  38. package/build/commands/build/version/sync.js +20 -22
  39. package/build/commands/build/view.js +12 -14
  40. package/build/commands/channel/create.js +17 -19
  41. package/build/commands/channel/delete.js +18 -20
  42. package/build/commands/channel/edit.js +20 -22
  43. package/build/commands/channel/list.js +12 -14
  44. package/build/commands/channel/pause.js +20 -22
  45. package/build/commands/channel/resume.js +20 -22
  46. package/build/commands/channel/rollout.js +74 -76
  47. package/build/commands/channel/view.js +18 -20
  48. package/build/commands/config.js +21 -23
  49. package/build/commands/credentials/configure-build.js +21 -23
  50. package/build/commands/credentials/index.js +13 -15
  51. package/build/commands/device/create.js +6 -8
  52. package/build/commands/device/delete.js +12 -14
  53. package/build/commands/device/list.js +12 -14
  54. package/build/commands/device/rename.js +13 -15
  55. package/build/commands/device/view.js +8 -10
  56. package/build/commands/diagnostics.js +6 -8
  57. package/build/commands/env/create.js +39 -41
  58. package/build/commands/env/delete.js +25 -27
  59. package/build/commands/env/exec.js +22 -24
  60. package/build/commands/env/get.js +26 -28
  61. package/build/commands/env/link.js +27 -29
  62. package/build/commands/env/list.js +27 -29
  63. package/build/commands/env/pull.js +23 -25
  64. package/build/commands/env/push.js +21 -23
  65. package/build/commands/env/unlink.js +23 -25
  66. package/build/commands/env/update.js +38 -40
  67. package/build/commands/fingerprint/compare.d.ts +28 -0
  68. package/build/commands/fingerprint/compare.js +324 -0
  69. package/build/commands/metadata/lint.js +18 -20
  70. package/build/commands/metadata/pull.js +15 -17
  71. package/build/commands/metadata/push.js +15 -17
  72. package/build/commands/open.js +6 -8
  73. package/build/commands/project/info.js +6 -8
  74. package/build/commands/project/init.js +26 -28
  75. package/build/commands/project/onboarding.js +10 -12
  76. package/build/commands/secret/create.js +30 -32
  77. package/build/commands/secret/delete.js +14 -16
  78. package/build/commands/secret/list.js +7 -9
  79. package/build/commands/secret/push.js +23 -25
  80. package/build/commands/submit/internal.js +23 -25
  81. package/build/commands/submit.js +54 -56
  82. package/build/commands/update/configure.js +18 -20
  83. package/build/commands/update/delete.js +16 -18
  84. package/build/commands/update/edit.js +25 -27
  85. package/build/commands/update/index.js +65 -67
  86. package/build/commands/update/list.js +21 -23
  87. package/build/commands/update/republish.js +45 -47
  88. package/build/commands/update/roll-back-to-embedded.d.ts +2 -1
  89. package/build/commands/update/roll-back-to-embedded.js +92 -84
  90. package/build/commands/update/rollback.js +7 -7
  91. package/build/commands/update/view.js +16 -18
  92. package/build/commands/webhook/create.js +20 -22
  93. package/build/commands/webhook/delete.js +17 -19
  94. package/build/commands/webhook/list.js +14 -16
  95. package/build/commands/webhook/update.js +23 -25
  96. package/build/commands/webhook/view.js +13 -15
  97. package/build/commands/worker/alias.js +30 -32
  98. package/build/commands/worker/deploy.js +38 -40
  99. package/build/commands/workflow/create.js +16 -18
  100. package/build/commands/workflow/run.js +13 -15
  101. package/build/commands/workflow/validate.js +18 -20
  102. package/build/credentials/android/AndroidCredentialsProvider.js +3 -1
  103. package/build/credentials/android/actions/AssignFcm.js +1 -0
  104. package/build/credentials/android/actions/AssignGoogleServiceAccountKeyForFcmV1.js +1 -0
  105. package/build/credentials/android/actions/AssignGoogleServiceAccountKeyForSubmissions.js +1 -0
  106. package/build/credentials/android/actions/CreateFcm.js +1 -0
  107. package/build/credentials/android/actions/CreateGoogleServiceAccountKey.js +1 -0
  108. package/build/credentials/android/actions/CreateKeystore.js +1 -0
  109. package/build/credentials/android/actions/DownloadKeystore.js +2 -0
  110. package/build/credentials/android/actions/RemoveFcm.js +1 -0
  111. package/build/credentials/android/actions/RemoveGoogleServiceAccountKey.js +2 -0
  112. package/build/credentials/android/actions/RemoveKeystore.js +1 -0
  113. package/build/credentials/android/actions/SetUpBuildCredentials.js +1 -0
  114. package/build/credentials/android/actions/SetUpBuildCredentialsFromCredentialsJson.js +1 -0
  115. package/build/credentials/android/actions/SetUpGoogleServiceAccountKeyForFcmV1.js +1 -0
  116. package/build/credentials/android/actions/SetUpGoogleServiceAccountKeyForSubmissions.js +1 -0
  117. package/build/credentials/android/actions/UseExistingGoogleServiceAccountKey.js +1 -0
  118. package/build/credentials/context.js +14 -5
  119. package/build/credentials/errors.js +1 -0
  120. package/build/credentials/ios/IosCredentialsProvider.js +3 -1
  121. package/build/credentials/ios/actions/AssignAscApiKey.js +1 -0
  122. package/build/credentials/ios/actions/AssignPushKey.js +1 -0
  123. package/build/credentials/ios/actions/ConfigureProvisioningProfile.js +4 -0
  124. package/build/credentials/ios/actions/CreateAscApiKey.js +1 -0
  125. package/build/credentials/ios/actions/CreateDistributionCertificate.js +1 -0
  126. package/build/credentials/ios/actions/CreateProvisioningProfile.js +3 -0
  127. package/build/credentials/ios/actions/CreatePushKey.js +1 -0
  128. package/build/credentials/ios/actions/RemoveAscApiKey.js +2 -0
  129. package/build/credentials/ios/actions/RemoveDistributionCertificate.js +3 -0
  130. package/build/credentials/ios/actions/RemoveProvisioningProfile.js +2 -0
  131. package/build/credentials/ios/actions/RemovePushKey.js +2 -0
  132. package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +1 -0
  133. package/build/credentials/ios/actions/SetUpAscApiKey.js +9 -7
  134. package/build/credentials/ios/actions/SetUpBuildCredentials.js +1 -0
  135. package/build/credentials/ios/actions/SetUpBuildCredentialsFromCredentialsJson.js +3 -0
  136. package/build/credentials/ios/actions/SetUpDistributionCertificate.js +3 -0
  137. package/build/credentials/ios/actions/SetUpInternalProvisioningProfile.js +1 -0
  138. package/build/credentials/ios/actions/SetUpProvisioningProfile.js +3 -0
  139. package/build/credentials/ios/actions/SetUpPushKey.js +1 -0
  140. package/build/credentials/ios/actions/SetUpTargetBuildCredentials.js +1 -0
  141. package/build/credentials/ios/actions/SetUpTargetBuildCredentialsFromCredentialsJson.js +3 -0
  142. package/build/credentials/ios/actions/UpdateCredentialsJson.js +3 -0
  143. package/build/credentials/ios/appstore/AppStoreApi.js +2 -0
  144. package/build/credentials/manager/CheckBuildProfileFlagAgainstEasJson.js +3 -0
  145. package/build/credentials/manager/CreateAndroidBuildCredentials.js +1 -0
  146. package/build/credentials/manager/ManageAndroid.js +2 -0
  147. package/build/credentials/manager/ManageIos.js +2 -0
  148. package/build/credentials/manager/SelectAndroidBuildCredentials.js +2 -0
  149. package/build/credentials/manager/SelectBuildProfileFromEasJson.js +2 -0
  150. package/build/credentials/manager/SelectIosDistributionTypeGraphqlFromBuildProfile.js +1 -0
  151. package/build/credentials/manager/SelectPlatform.js +7 -0
  152. package/build/credentials/manager/SetDefaultAndroidKeystore.js +1 -0
  153. package/build/credentials/manager/SetUpAndroidBuildCredentials.js +1 -0
  154. package/build/credentials/manager/SetUpBuildCredentialsCommandAction.js +9 -0
  155. package/build/credentials/manager/SetUpIosBuildCredentials.js +1 -0
  156. package/build/devices/actions/create/action.js +4 -0
  157. package/build/devices/manager.js +4 -0
  158. package/build/fetch.js +1 -0
  159. package/build/graphql/generated.d.ts +175 -0
  160. package/build/graphql/generated.js +8 -3
  161. package/build/graphql/queries/BuildQuery.d.ts +4 -1
  162. package/build/graphql/queries/BuildQuery.js +19 -0
  163. package/build/graphql/types/Build.d.ts +1 -0
  164. package/build/graphql/types/Build.js +15 -1
  165. package/build/graphql/types/Fingerprint.d.ts +1 -0
  166. package/build/graphql/types/Fingerprint.js +12 -0
  167. package/build/log.js +2 -2
  168. package/build/metadata/apple/config/reader.js +1 -0
  169. package/build/metadata/apple/config/writer.js +1 -0
  170. package/build/metadata/apple/tasks/age-rating.js +1 -4
  171. package/build/metadata/apple/tasks/app-info.js +1 -4
  172. package/build/metadata/apple/tasks/app-review-detail.js +1 -4
  173. package/build/metadata/apple/tasks/app-version.js +2 -1
  174. package/build/metadata/errors.js +5 -0
  175. package/build/rollout/actions/CreateRollout.d.ts +9 -10
  176. package/build/rollout/actions/CreateRollout.js +2 -0
  177. package/build/rollout/actions/EditRollout.d.ts +2 -3
  178. package/build/rollout/actions/EditRollout.js +2 -0
  179. package/build/rollout/actions/EndRollout.d.ts +4 -6
  180. package/build/rollout/actions/EndRollout.js +2 -0
  181. package/build/rollout/actions/ManageRollout.d.ts +2 -3
  182. package/build/rollout/actions/ManageRollout.js +2 -0
  183. package/build/rollout/actions/NonInteractiveRollout.d.ts +6 -27
  184. package/build/rollout/actions/NonInteractiveRollout.js +1 -0
  185. package/build/rollout/actions/RolloutMainMenu.d.ts +6 -7
  186. package/build/rollout/actions/RolloutMainMenu.js +1 -0
  187. package/build/rollout/actions/SelectRuntime.d.ts +6 -20
  188. package/build/rollout/actions/SelectRuntime.js +3 -0
  189. package/build/submit/BaseSubmitter.js +4 -0
  190. package/build/submit/android/AndroidSubmitCommand.js +1 -0
  191. package/build/submit/ios/IosSubmitCommand.js +1 -0
  192. package/build/update/getBranchFromChannelNameAndCreateAndLinkIfNotExistsAsync.js +3 -3
  193. package/build/user/SessionManager.js +2 -0
  194. package/build/utils/fingerprint.d.ts +97 -0
  195. package/build/utils/fingerprint.js +5 -0
  196. package/build/utils/fingerprintCli.d.ts +5 -7
  197. package/build/utils/fingerprintCli.js +11 -1
  198. package/build/utils/fingerprintDiff.d.ts +33 -0
  199. package/build/utils/fingerprintDiff.js +122 -0
  200. package/build/vcs/clients/git.js +1 -0
  201. package/build/vcs/local.js +2 -1
  202. package/oclif.manifest.json +51 -7
  203. package/package.json +9 -7
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
@@ -10,9 +9,23 @@ const log_1 = tslib_1.__importDefault(require("../../log"));
10
9
  const utils_1 = require("../../update/utils");
11
10
  const json_1 = require("../../utils/json");
12
11
  class UpdateView extends EasCommand_1.default {
12
+ static description = 'update group details';
13
+ static args = [
14
+ {
15
+ name: 'groupId',
16
+ required: true,
17
+ description: 'The ID of an update group.',
18
+ },
19
+ ];
20
+ static flags = {
21
+ ...flags_1.EasJsonOnlyFlag,
22
+ };
23
+ static contextDefinition = {
24
+ ...this.ContextOptions.LoggedIn,
25
+ };
13
26
  async runAsync() {
14
- const { args: { groupId }, flags: { json: jsonFlag }, } = await this.parse(_a);
15
- const { loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, { nonInteractive: true });
27
+ const { args: { groupId }, flags: { json: jsonFlag }, } = await this.parse(UpdateView);
28
+ const { loggedIn: { graphqlClient }, } = await this.getContextAsync(UpdateView, { nonInteractive: true });
16
29
  if (jsonFlag) {
17
30
  (0, json_1.enableJsonOutput)();
18
31
  }
@@ -27,19 +40,4 @@ class UpdateView extends EasCommand_1.default {
27
40
  }
28
41
  }
29
42
  }
30
- _a = UpdateView;
31
- UpdateView.description = 'update group details';
32
- UpdateView.args = [
33
- {
34
- name: 'groupId',
35
- required: true,
36
- description: 'The ID of an update group.',
37
- },
38
- ];
39
- UpdateView.flags = {
40
- ...flags_1.EasJsonOnlyFlag,
41
- };
42
- UpdateView.contextDefinition = {
43
- ..._a.ContextOptions.LoggedIn,
44
- };
45
43
  exports.default = UpdateView;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const core_1 = require("@oclif/core");
@@ -10,9 +9,27 @@ const WebhookMutation_1 = require("../../graphql/mutations/WebhookMutation");
10
9
  const ora_1 = require("../../ora");
11
10
  const input_1 = require("../../webhooks/input");
12
11
  class WebhookCreate extends EasCommand_1.default {
12
+ static description = 'create a webhook';
13
+ static flags = {
14
+ event: core_1.Flags.enum({
15
+ description: 'Event type that triggers the webhook',
16
+ options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
17
+ }),
18
+ url: core_1.Flags.string({
19
+ description: 'Webhook URL',
20
+ }),
21
+ secret: core_1.Flags.string({
22
+ description: "Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header.",
23
+ }),
24
+ ...flags_1.EASNonInteractiveFlag,
25
+ };
26
+ static contextDefinition = {
27
+ ...this.ContextOptions.ProjectId,
28
+ ...this.ContextOptions.LoggedIn,
29
+ };
13
30
  async runAsync() {
14
- const { flags } = await this.parse(_a);
15
- const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
31
+ const { flags } = await this.parse(WebhookCreate);
32
+ const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(WebhookCreate, {
16
33
  nonInteractive: flags['non-interactive'],
17
34
  });
18
35
  const webhookInputParams = await (0, input_1.prepareInputParamsAsync)(flags);
@@ -27,23 +44,4 @@ class WebhookCreate extends EasCommand_1.default {
27
44
  }
28
45
  }
29
46
  }
30
- _a = WebhookCreate;
31
- WebhookCreate.description = 'create a webhook';
32
- WebhookCreate.flags = {
33
- event: core_1.Flags.enum({
34
- description: 'Event type that triggers the webhook',
35
- options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
36
- }),
37
- url: core_1.Flags.string({
38
- description: 'Webhook URL',
39
- }),
40
- secret: core_1.Flags.string({
41
- description: "Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header.",
42
- }),
43
- ...flags_1.EASNonInteractiveFlag,
44
- };
45
- WebhookCreate.contextDefinition = {
46
- ..._a.ContextOptions.ProjectId,
47
- ..._a.ContextOptions.LoggedIn,
48
- };
49
47
  exports.default = WebhookCreate;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const assert_1 = tslib_1.__importDefault(require("assert"));
@@ -14,9 +13,24 @@ const ora_1 = require("../../ora");
14
13
  const prompts_1 = require("../../prompts");
15
14
  const formatWebhook_1 = require("../../webhooks/formatWebhook");
16
15
  class WebhookDelete extends EasCommand_1.default {
16
+ static description = 'delete a webhook';
17
+ static args = [
18
+ {
19
+ name: 'ID',
20
+ required: false,
21
+ description: 'ID of the webhook to delete',
22
+ },
23
+ ];
24
+ static flags = {
25
+ ...flags_1.EASNonInteractiveFlag,
26
+ };
27
+ static contextDefinition = {
28
+ ...this.ContextOptions.ProjectId,
29
+ ...this.ContextOptions.LoggedIn,
30
+ };
17
31
  async runAsync() {
18
- let { args: { ID: webhookId }, flags: { 'non-interactive': nonInteractive }, } = await this.parse(_a);
19
- const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
32
+ let { args: { ID: webhookId }, flags: { 'non-interactive': nonInteractive }, } = await this.parse(WebhookDelete);
33
+ const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(WebhookDelete, {
20
34
  nonInteractive,
21
35
  });
22
36
  let webhook = webhookId && (await WebhookQuery_1.WebhookQuery.byIdAsync(graphqlClient, webhookId));
@@ -65,22 +79,6 @@ class WebhookDelete extends EasCommand_1.default {
65
79
  }
66
80
  }
67
81
  }
68
- _a = WebhookDelete;
69
- WebhookDelete.description = 'delete a webhook';
70
- WebhookDelete.args = [
71
- {
72
- name: 'ID',
73
- required: false,
74
- description: 'ID of the webhook to delete',
75
- },
76
- ];
77
- WebhookDelete.flags = {
78
- ...flags_1.EASNonInteractiveFlag,
79
- };
80
- WebhookDelete.contextDefinition = {
81
- ..._a.ContextOptions.ProjectId,
82
- ..._a.ContextOptions.LoggedIn,
83
- };
84
82
  exports.default = WebhookDelete;
85
83
  async function fetchWebhooksByAppIdAsync(graphqlClient, appId) {
86
84
  const spinner = (0, ora_1.ora)('Fetching webhooks').start();
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const core_1 = require("@oclif/core");
@@ -14,12 +13,24 @@ const projectUtils_1 = require("../../project/projectUtils");
14
13
  const json_1 = require("../../utils/json");
15
14
  const formatWebhook_1 = require("../../webhooks/formatWebhook");
16
15
  class WebhookList extends EasCommand_1.default {
16
+ static description = 'list webhooks';
17
+ static flags = {
18
+ event: core_1.Flags.enum({
19
+ description: 'Event type that triggers the webhook',
20
+ options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
21
+ }),
22
+ ...flags_1.EasJsonOnlyFlag,
23
+ };
24
+ static contextDefinition = {
25
+ ...this.ContextOptions.ProjectId,
26
+ ...this.ContextOptions.LoggedIn,
27
+ };
17
28
  async runAsync() {
18
- const { flags: { event, json }, } = await this.parse(_a);
29
+ const { flags: { event, json }, } = await this.parse(WebhookList);
19
30
  if (json) {
20
31
  (0, json_1.enableJsonOutput)();
21
32
  }
22
- const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
33
+ const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(WebhookList, {
23
34
  nonInteractive: true,
24
35
  });
25
36
  const projectDisplayName = await (0, projectUtils_1.getDisplayNameForProjectIdAsync)(graphqlClient, projectId);
@@ -48,17 +59,4 @@ class WebhookList extends EasCommand_1.default {
48
59
  }
49
60
  }
50
61
  }
51
- _a = WebhookList;
52
- WebhookList.description = 'list webhooks';
53
- WebhookList.flags = {
54
- event: core_1.Flags.enum({
55
- description: 'Event type that triggers the webhook',
56
- options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
57
- }),
58
- ...flags_1.EasJsonOnlyFlag,
59
- };
60
- WebhookList.contextDefinition = {
61
- ..._a.ContextOptions.ProjectId,
62
- ..._a.ContextOptions.LoggedIn,
63
- };
64
62
  exports.default = WebhookList;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const core_1 = require("@oclif/core");
@@ -12,9 +11,30 @@ const ora_1 = require("../../ora");
12
11
  const pick_1 = tslib_1.__importDefault(require("../../utils/expodash/pick"));
13
12
  const input_1 = require("../../webhooks/input");
14
13
  class WebhookUpdate extends EasCommand_1.default {
14
+ static description = 'update a webhook';
15
+ static flags = {
16
+ id: core_1.Flags.string({
17
+ description: 'Webhook ID',
18
+ required: true,
19
+ }),
20
+ event: core_1.Flags.enum({
21
+ description: 'Event type that triggers the webhook',
22
+ options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
23
+ }),
24
+ url: core_1.Flags.string({
25
+ description: 'Webhook URL',
26
+ }),
27
+ secret: core_1.Flags.string({
28
+ description: "Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header.",
29
+ }),
30
+ ...flags_1.EASNonInteractiveFlag,
31
+ };
32
+ static contextDefinition = {
33
+ ...this.ContextOptions.LoggedIn,
34
+ };
15
35
  async runAsync() {
16
- const { flags } = await this.parse(_a);
17
- const { loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, { nonInteractive: flags['non-interactive'] });
36
+ const { flags } = await this.parse(WebhookUpdate);
37
+ const { loggedIn: { graphqlClient }, } = await this.getContextAsync(WebhookUpdate, { nonInteractive: flags['non-interactive'] });
18
38
  const webhookId = flags.id;
19
39
  const webhook = await WebhookQuery_1.WebhookQuery.byIdAsync(graphqlClient, webhookId);
20
40
  const webhookInputParams = await (0, input_1.prepareInputParamsAsync)((0, pick_1.default)(flags, ['event', 'url', 'secret', 'non-interactive']), webhook);
@@ -29,26 +49,4 @@ class WebhookUpdate extends EasCommand_1.default {
29
49
  }
30
50
  }
31
51
  }
32
- _a = WebhookUpdate;
33
- WebhookUpdate.description = 'update a webhook';
34
- WebhookUpdate.flags = {
35
- id: core_1.Flags.string({
36
- description: 'Webhook ID',
37
- required: true,
38
- }),
39
- event: core_1.Flags.enum({
40
- description: 'Event type that triggers the webhook',
41
- options: [generated_1.WebhookType.Build, generated_1.WebhookType.Submit],
42
- }),
43
- url: core_1.Flags.string({
44
- description: 'Webhook URL',
45
- }),
46
- secret: core_1.Flags.string({
47
- description: "Secret used to create a hash signature of the request payload, provided in the 'Expo-Signature' header.",
48
- }),
49
- ...flags_1.EASNonInteractiveFlag,
50
- };
51
- WebhookUpdate.contextDefinition = {
52
- ..._a.ContextOptions.LoggedIn,
53
- };
54
52
  exports.default = WebhookUpdate;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
@@ -8,9 +7,20 @@ const log_1 = tslib_1.__importDefault(require("../../log"));
8
7
  const ora_1 = require("../../ora");
9
8
  const formatWebhook_1 = require("../../webhooks/formatWebhook");
10
9
  class WebhookView extends EasCommand_1.default {
10
+ static description = 'view a webhook';
11
+ static args = [
12
+ {
13
+ name: 'ID',
14
+ required: true,
15
+ description: 'ID of the webhook to view',
16
+ },
17
+ ];
18
+ static contextDefinition = {
19
+ ...this.ContextOptions.LoggedIn,
20
+ };
11
21
  async runAsync() {
12
- const { args: { ID: webhookId }, } = await this.parse(_a);
13
- const { loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, { nonInteractive: true });
22
+ const { args: { ID: webhookId }, } = await this.parse(WebhookView);
23
+ const { loggedIn: { graphqlClient }, } = await this.getContextAsync(WebhookView, { nonInteractive: true });
14
24
  const spinner = (0, ora_1.ora)(`Fetching the webhook details for ID ${webhookId}`).start();
15
25
  try {
16
26
  const webhook = await WebhookQuery_1.WebhookQuery.byIdAsync(graphqlClient, webhookId);
@@ -23,16 +33,4 @@ class WebhookView extends EasCommand_1.default {
23
33
  }
24
34
  }
25
35
  }
26
- _a = WebhookView;
27
- WebhookView.description = 'view a webhook';
28
- WebhookView.args = [
29
- {
30
- name: 'ID',
31
- required: true,
32
- description: 'ID of the webhook to view',
33
- },
34
- ];
35
- WebhookView.contextDefinition = {
36
- ..._a.ContextOptions.LoggedIn,
37
- };
38
36
  exports.default = WebhookView;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const core_1 = require("@oclif/core");
@@ -13,14 +12,42 @@ const json_1 = require("../../utils/json");
13
12
  const deployment_1 = require("../../worker/deployment");
14
13
  const logs_1 = require("../../worker/utils/logs");
15
14
  class WorkerAlias extends EasCommand_1.default {
15
+ static description = 'Assign deployment aliases';
16
+ static aliases = ['deploy:alias', 'deploy:promote'];
17
+ // TODO(@kitten): Keep command hidden until worker deployments are live
18
+ static hidden = true;
19
+ static state = 'beta';
20
+ static flags = {
21
+ prod: core_1.Flags.boolean({
22
+ aliases: ['production'],
23
+ description: 'Promote an existing deployment to production.',
24
+ default: false,
25
+ }),
26
+ alias: core_1.Flags.string({
27
+ description: 'Custom alias to assign to the existing deployment.',
28
+ helpValue: 'name',
29
+ required: false,
30
+ }),
31
+ id: core_1.Flags.string({
32
+ description: 'Unique identifier of an existing deployment.',
33
+ helpValue: 'xyz123',
34
+ required: false,
35
+ }),
36
+ ...flags_1.EasNonInteractiveAndJsonFlags,
37
+ };
38
+ static contextDefinition = {
39
+ ...this.ContextOptions.DynamicProjectConfig,
40
+ ...this.ContextOptions.ProjectDir,
41
+ ...this.ContextOptions.LoggedIn,
42
+ };
16
43
  async runAsync() {
17
- const { flags: rawFlags } = await this.parse(_a);
44
+ const { flags: rawFlags } = await this.parse(WorkerAlias);
18
45
  const flags = this.sanitizeFlags(rawFlags);
19
46
  if (flags.json) {
20
47
  (0, json_1.enableJsonOutput)();
21
48
  }
22
49
  log_1.default.warn('EAS Worker Deployments are in beta and subject to breaking changes.');
23
- const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, } = await this.getContextAsync(_a, {
50
+ const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, } = await this.getContextAsync(WorkerAlias, {
24
51
  nonInteractive: true,
25
52
  withServerSideEnvironment: null,
26
53
  });
@@ -100,35 +127,6 @@ class WorkerAlias extends EasCommand_1.default {
100
127
  };
101
128
  }
102
129
  }
103
- _a = WorkerAlias;
104
- WorkerAlias.description = 'Assign deployment aliases';
105
- WorkerAlias.aliases = ['deploy:alias', 'deploy:promote'];
106
- // TODO(@kitten): Keep command hidden until worker deployments are live
107
- WorkerAlias.hidden = true;
108
- WorkerAlias.state = 'beta';
109
- WorkerAlias.flags = {
110
- prod: core_1.Flags.boolean({
111
- aliases: ['production'],
112
- description: 'Promote an existing deployment to production.',
113
- default: false,
114
- }),
115
- alias: core_1.Flags.string({
116
- description: 'Custom alias to assign to the existing deployment.',
117
- helpValue: 'name',
118
- required: false,
119
- }),
120
- id: core_1.Flags.string({
121
- description: 'Unique identifier of an existing deployment.',
122
- helpValue: 'xyz123',
123
- required: false,
124
- }),
125
- ...flags_1.EasNonInteractiveAndJsonFlags,
126
- };
127
- WorkerAlias.contextDefinition = {
128
- ..._a.ContextOptions.DynamicProjectConfig,
129
- ..._a.ContextOptions.ProjectDir,
130
- ..._a.ContextOptions.LoggedIn,
131
- };
132
130
  exports.default = WorkerAlias;
133
131
  async function resolveDeploymentAliasAsync(flags) {
134
132
  if (flags.aliasName?.trim()) {
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const timeago_js_1 = require("@expo/timeago.js");
@@ -22,14 +21,50 @@ const isDirectory = (directoryPath) => node_fs_1.default.promises
22
21
  .then(stat => stat.isDirectory())
23
22
  .catch(() => false);
24
23
  class WorkerDeploy extends EasCommand_1.default {
24
+ static description = 'Deploy your Expo web build';
25
+ static aliases = ['deploy'];
26
+ static usage = [(0, chalk_1.default) `deploy {dim [options]}`, `deploy --prod`];
27
+ // TODO(@kitten): Keep command hidden until worker deployments are live
28
+ static hidden = true;
29
+ static state = 'beta';
30
+ static flags = {
31
+ prod: core_1.Flags.boolean({
32
+ aliases: ['production'],
33
+ description: 'Create a new production deployment.',
34
+ default: false,
35
+ }),
36
+ alias: core_1.Flags.string({
37
+ description: 'Custom alias to assign to the new deployment.',
38
+ helpValue: 'name',
39
+ }),
40
+ id: core_1.Flags.string({
41
+ description: 'Custom unique identifier for the new deployment.',
42
+ helpValue: 'xyz123',
43
+ }),
44
+ 'export-dir': core_1.Flags.string({
45
+ description: 'Directory where the Expo project was exported.',
46
+ helpValue: 'dir',
47
+ default: 'dist',
48
+ }),
49
+ environment: {
50
+ ...flags_1.EASEnvironmentFlag.environment,
51
+ description: 'Deploy with EAS Environment Variables matching the specified environment.',
52
+ },
53
+ ...flags_1.EasNonInteractiveAndJsonFlags,
54
+ };
55
+ static contextDefinition = {
56
+ ...this.ContextOptions.DynamicProjectConfig,
57
+ ...this.ContextOptions.ProjectDir,
58
+ ...this.ContextOptions.LoggedIn,
59
+ };
25
60
  async runAsync() {
26
- const { flags: rawFlags } = await this.parse(_a);
61
+ const { flags: rawFlags } = await this.parse(WorkerDeploy);
27
62
  const flags = this.sanitizeFlags(rawFlags);
28
63
  if (flags.json) {
29
64
  (0, json_1.enableJsonOutput)();
30
65
  }
31
66
  log_1.default.warn('EAS Worker Deployments are in beta and subject to breaking changes.');
32
- const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, projectDir, } = await this.getContextAsync(_a, { ...flags, withServerSideEnvironment: null });
67
+ const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, projectDir, } = await this.getContextAsync(WorkerDeploy, { ...flags, withServerSideEnvironment: null });
33
68
  const projectDist = await resolveExportedProjectAsync(flags, projectDir);
34
69
  const { projectId } = await getDynamicPrivateProjectConfigAsync();
35
70
  logExportedProjectInfo(projectDist);
@@ -252,43 +287,6 @@ class WorkerDeploy extends EasCommand_1.default {
252
287
  };
253
288
  }
254
289
  }
255
- _a = WorkerDeploy;
256
- WorkerDeploy.description = 'Deploy your Expo web build';
257
- WorkerDeploy.aliases = ['deploy'];
258
- WorkerDeploy.usage = [(0, chalk_1.default) `deploy {dim [options]}`, `deploy --prod`];
259
- // TODO(@kitten): Keep command hidden until worker deployments are live
260
- WorkerDeploy.hidden = true;
261
- WorkerDeploy.state = 'beta';
262
- WorkerDeploy.flags = {
263
- prod: core_1.Flags.boolean({
264
- aliases: ['production'],
265
- description: 'Create a new production deployment.',
266
- default: false,
267
- }),
268
- alias: core_1.Flags.string({
269
- description: 'Custom alias to assign to the new deployment.',
270
- helpValue: 'name',
271
- }),
272
- id: core_1.Flags.string({
273
- description: 'Custom unique identifier for the new deployment.',
274
- helpValue: 'xyz123',
275
- }),
276
- 'export-dir': core_1.Flags.string({
277
- description: 'Directory where the Expo project was exported.',
278
- helpValue: 'dir',
279
- default: 'dist',
280
- }),
281
- environment: {
282
- ...flags_1.EASEnvironmentFlag.environment,
283
- description: 'Deploy with EAS Environment Variables matching the specified environment.',
284
- },
285
- ...flags_1.EasNonInteractiveAndJsonFlags,
286
- };
287
- WorkerDeploy.contextDefinition = {
288
- ..._a.ContextOptions.DynamicProjectConfig,
289
- ..._a.ContextOptions.ProjectDir,
290
- ..._a.ContextOptions.LoggedIn,
291
- };
292
290
  exports.default = WorkerDeploy;
293
291
  async function resolveExportedProjectAsync(flags, projectDir) {
294
292
  const exportPath = path.join(projectDir, flags.exportDir);
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  exports.WorkflowCreate = void 0;
5
4
  const tslib_1 = require("tslib");
@@ -26,9 +25,23 @@ jobs:
26
25
  - run: echo "Hello, World"
27
26
  `;
28
27
  class WorkflowCreate extends EasCommand_1.default {
28
+ static description = 'create a new workflow configuration YAML file';
29
+ static args = [
30
+ {
31
+ name: 'name',
32
+ description: 'Name of the workflow file (must end with .yml or .yaml)',
33
+ required: false,
34
+ },
35
+ ];
36
+ static flags = {
37
+ ...flags_1.EASNonInteractiveFlag,
38
+ };
39
+ static contextDefinition = {
40
+ ...this.ContextOptions.ProjectDir,
41
+ };
29
42
  async runAsync() {
30
- const { args: { name: argFileName }, flags, } = await this.parse(_a);
31
- const { projectDir } = await this.getContextAsync(_a, {
43
+ const { args: { name: argFileName }, flags, } = await this.parse(WorkflowCreate);
44
+ const { projectDir } = await this.getContextAsync(WorkflowCreate, {
32
45
  nonInteractive: flags['non-interactive'],
33
46
  });
34
47
  let fileName = argFileName;
@@ -83,18 +96,3 @@ class WorkflowCreate extends EasCommand_1.default {
83
96
  }
84
97
  }
85
98
  exports.WorkflowCreate = WorkflowCreate;
86
- _a = WorkflowCreate;
87
- WorkflowCreate.description = 'create a new workflow configuration YAML file';
88
- WorkflowCreate.args = [
89
- {
90
- name: 'name',
91
- description: 'Name of the workflow file (must end with .yml or .yaml)',
92
- required: false,
93
- },
94
- ];
95
- WorkflowCreate.flags = {
96
- ...flags_1.EASNonInteractiveFlag,
97
- };
98
- WorkflowCreate.contextDefinition = {
99
- ..._a.ContextOptions.ProjectDir,
100
- };
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  const tslib_1 = require("tslib");
5
4
  const core_1 = require("@urql/core");
@@ -16,9 +15,20 @@ const uploadAccountScopedEasJsonAsync_1 = require("../../project/uploadAccountSc
16
15
  const uploadAccountScopedProjectSourceAsync_1 = require("../../project/uploadAccountScopedProjectSourceAsync");
17
16
  const workflowFile_1 = require("../../utils/workflowFile");
18
17
  class WorkflowRun extends EasCommand_1.default {
18
+ static description = 'Run an EAS workflow';
19
+ static args = [{ name: 'file', description: 'Path to the workflow file to run' }];
20
+ static flags = {
21
+ ...flags_1.EASNonInteractiveFlag,
22
+ };
23
+ static contextDefinition = {
24
+ ...this.ContextOptions.DynamicProjectConfig,
25
+ ...this.ContextOptions.ProjectDir,
26
+ ...this.ContextOptions.Vcs,
27
+ ...this.ContextOptions.LoggedIn,
28
+ };
19
29
  async runAsync() {
20
- const { flags, args } = await this.parse(_a);
21
- const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, vcsClient, projectDir, } = await this.getContextAsync(_a, {
30
+ const { flags, args } = await this.parse(WorkflowRun);
31
+ const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, vcsClient, projectDir, } = await this.getContextAsync(WorkflowRun, {
22
32
  nonInteractive: flags['non-interactive'],
23
33
  withServerSideEnvironment: null,
24
34
  });
@@ -95,16 +105,4 @@ class WorkflowRun extends EasCommand_1.default {
95
105
  }
96
106
  }
97
107
  }
98
- _a = WorkflowRun;
99
- WorkflowRun.description = 'Run an EAS workflow';
100
- WorkflowRun.args = [{ name: 'file', description: 'Path to the workflow file to run' }];
101
- WorkflowRun.flags = {
102
- ...flags_1.EASNonInteractiveFlag,
103
- };
104
- WorkflowRun.contextDefinition = {
105
- ..._a.ContextOptions.DynamicProjectConfig,
106
- ..._a.ContextOptions.ProjectDir,
107
- ..._a.ContextOptions.Vcs,
108
- ..._a.ContextOptions.LoggedIn,
109
- };
110
108
  exports.default = WorkflowRun;
@@ -1,5 +1,4 @@
1
1
  "use strict";
2
- var _a;
3
2
  Object.defineProperty(exports, "__esModule", { value: true });
4
3
  exports.WorkflowValidate = void 0;
5
4
  const tslib_1 = require("tslib");
@@ -13,9 +12,25 @@ const ora_1 = require("../../ora");
13
12
  const projectUtils_1 = require("../../project/projectUtils");
14
13
  const workflowFile_1 = require("../../utils/workflowFile");
15
14
  class WorkflowValidate extends EasCommand_1.default {
15
+ static description = 'validate a workflow configuration yaml file';
16
+ static args = [
17
+ {
18
+ name: 'path',
19
+ description: 'Path to the workflow configuration YAML file (must end with .yml or .yaml)',
20
+ required: true,
21
+ },
22
+ ];
23
+ static flags = {
24
+ ...flags_1.EASNonInteractiveFlag,
25
+ };
26
+ static contextDefinition = {
27
+ ...this.ContextOptions.DynamicProjectConfig,
28
+ ...this.ContextOptions.ProjectDir,
29
+ ...this.ContextOptions.LoggedIn,
30
+ };
16
31
  async runAsync() {
17
- const { args: { path: filePath }, flags, } = await this.parse(_a);
18
- const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, projectDir, } = await this.getContextAsync(_a, {
32
+ const { args: { path: filePath }, flags, } = await this.parse(WorkflowValidate);
33
+ const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, projectDir, } = await this.getContextAsync(WorkflowValidate, {
19
34
  nonInteractive: flags['non-interactive'],
20
35
  withServerSideEnvironment: null,
21
36
  });
@@ -65,20 +80,3 @@ class WorkflowValidate extends EasCommand_1.default {
65
80
  }
66
81
  }
67
82
  exports.WorkflowValidate = WorkflowValidate;
68
- _a = WorkflowValidate;
69
- WorkflowValidate.description = 'validate a workflow configuration yaml file';
70
- WorkflowValidate.args = [
71
- {
72
- name: 'path',
73
- description: 'Path to the workflow configuration YAML file (must end with .yml or .yaml)',
74
- required: true,
75
- },
76
- ];
77
- WorkflowValidate.flags = {
78
- ...flags_1.EASNonInteractiveFlag,
79
- };
80
- WorkflowValidate.contextDefinition = {
81
- ..._a.ContextOptions.DynamicProjectConfig,
82
- ..._a.ContextOptions.ProjectDir,
83
- ..._a.ContextOptions.LoggedIn,
84
- };
@@ -7,10 +7,12 @@ const nullthrows_1 = tslib_1.__importDefault(require("nullthrows"));
7
7
  const SetUpBuildCredentials_1 = require("./actions/SetUpBuildCredentials");
8
8
  const credentialsJsonReader = tslib_1.__importStar(require("../credentialsJson/read"));
9
9
  class AndroidCredentialsProvider {
10
+ ctx;
11
+ options;
12
+ platform = eas_build_job_1.Platform.ANDROID;
10
13
  constructor(ctx, options) {
11
14
  this.ctx = ctx;
12
15
  this.options = options;
13
- this.platform = eas_build_job_1.Platform.ANDROID;
14
16
  }
15
17
  async getCredentialsAsync(src) {
16
18
  switch (src) {