eas-cli 20.5.1 → 21.0.1

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 (59) hide show
  1. package/README.md +171 -178
  2. package/build/analytics/AnalyticsManager.js +3 -0
  3. package/build/analytics/agent.d.ts +5 -0
  4. package/build/analytics/agent.js +26 -0
  5. package/build/build/utils/url.d.ts +1 -0
  6. package/build/build/utils/url.js +6 -1
  7. package/build/commandUtils/workflow/buildProfileUtils.d.ts +11 -29
  8. package/build/commandUtils/workflow/buildProfileUtils.js +47 -126
  9. package/build/commandUtils/workflow/creation.d.ts +11 -3
  10. package/build/commandUtils/workflow/creation.js +151 -261
  11. package/build/commands/browse.d.ts +17 -0
  12. package/build/commands/browse.js +90 -0
  13. package/build/commands/deploy/index.d.ts +1 -0
  14. package/build/commands/deploy/index.js +15 -1
  15. package/build/commands/integrations/posthog/dashboard.d.ts +1 -0
  16. package/build/commands/integrations/posthog/dashboard.js +30 -6
  17. package/build/commands/observe/metrics.js +1 -1
  18. package/build/commands/open.d.ts +1 -4
  19. package/build/commands/open.js +4 -32
  20. package/build/commands/project/delete.d.ts +16 -0
  21. package/build/commands/project/delete.js +129 -0
  22. package/build/commands/project/init.d.ts +0 -7
  23. package/build/commands/project/init.js +4 -274
  24. package/build/commands/simulator/get.js +57 -4
  25. package/build/commands/simulator/start.js +1 -0
  26. package/build/commands/workflow/create.d.ts +3 -0
  27. package/build/commands/workflow/create.js +118 -87
  28. package/build/credentials/ios/appstore/bundleIdCapabilities.js +9 -3
  29. package/build/graphql/generated.d.ts +253 -253
  30. package/build/graphql/generated.js +41 -4
  31. package/build/graphql/mutations/AppMutation.d.ts +2 -0
  32. package/build/graphql/mutations/AppMutation.js +19 -0
  33. package/build/graphql/mutations/PostHogMutation.d.ts +2 -1
  34. package/build/graphql/mutations/PostHogMutation.js +14 -0
  35. package/build/graphql/queries/DeviceRunSessionQuery.js +15 -0
  36. package/build/graphql/queries/UserQuery.js +0 -10
  37. package/build/graphql/queries/WorkflowRunQuery.js +1 -0
  38. package/build/integrations/asc/utils.js +6 -4
  39. package/build/observe/metricNames.d.ts +1 -1
  40. package/build/observe/metricNames.js +7 -6
  41. package/build/project/android/applicationId.d.ts +2 -1
  42. package/build/project/android/applicationId.js +19 -11
  43. package/build/project/ios/bundleIdentifier.d.ts +2 -1
  44. package/build/project/ios/bundleIdentifier.js +19 -11
  45. package/build/project/projectInitialization.d.ts +9 -0
  46. package/build/project/projectInitialization.js +277 -0
  47. package/build/project/publish.js +73 -40
  48. package/build/user/sudo.d.ts +14 -0
  49. package/build/user/sudo.js +62 -0
  50. package/build/worker/deployment.d.ts +11 -1
  51. package/build/worker/deployment.js +71 -22
  52. package/build/worker/queries.d.ts +2 -1
  53. package/build/worker/queries.js +18 -0
  54. package/oclif.manifest.json +1764 -1602
  55. package/package.json +9 -8
  56. package/build/commands/project/onboarding.d.ts +0 -14
  57. package/build/commands/project/onboarding.js +0 -362
  58. package/build/graphql/mutations/UserPreferencesMutation.d.ts +0 -10
  59. package/build/graphql/mutations/UserPreferencesMutation.js +0 -41
@@ -6,10 +6,10 @@
6
6
  * For more info and docs, visit https://graphql-code-generator.com/
7
7
  */
8
8
  Object.defineProperty(exports, "__esModule", { value: true });
9
- exports.ContinentCode = exports.BuildWorkflow = exports.BuildTrigger = exports.BuildStatus = exports.BuildRetryDisabledReason = exports.BuildResourceClass = exports.BuildPriority = exports.BuildPhase = exports.BuildMode = exports.BuildLimitThresholdExceededMetadataType = exports.BuildIosEnterpriseProvisioning = exports.BuildCredentialsSource = exports.BuildAnnotationType = exports.BackgroundJobState = exports.BackgroundJobResultType = exports.AuthProviderIdentifier = exports.AuthProtocolType = exports.AuditLogsExportFormat = exports.AssetMetadataStatus = exports.AssetMapSourceType = exports.AppsFilter = exports.AppleTeamType = exports.AppleDeviceClass = exports.AppUploadSessionType = exports.AppStoreConnectWorkflowConnectionStatus = exports.AppStoreConnectUserRole = exports.AppSort = exports.AppProfileImageWidth = exports.AppPrivacy = exports.AppPlatform = exports.AppObserveUpdatesOrderByField = exports.AppObserveUpdatesOrderByDirection = exports.AppObservePropertyType = exports.AppObservePlatform = exports.AppObserveNavigationRoutesOrderByField = exports.AppObserveEventsOrderByField = exports.AppObserveEventsOrderByDirection = exports.AppObserveErrorSeverity = exports.AppObserveErrorGroupsOrderBy = exports.AppObserveErrorBreakdownDimension = exports.AppObserveCustomEventNamesOrderByField = exports.AppObserveCustomEventNamesOrderByDirection = exports.AppInternalDistributionBuildPrivacy = exports.AndroidKeystoreType = exports.AndroidFcmVersion = exports.AndroidBuildType = exports.ActivityTimelineProjectActivityType = exports.AccountUploadSessionType = exports.AccountMemberType = exports.AccountAppsSortByField = void 0;
10
- exports.JobRunStatus = exports.JobRunPriority = exports.IosSchemeBuildConfiguration = exports.IosManagedBuildType = exports.IosDistributionType = exports.IosBuildType = exports.InvoiceDiscountType = exports.InsightsFilterType = exports.GitHubJobRunTriggerType = exports.GitHubJobRunTriggerRunStatus = exports.GitHubJobRunJobType = exports.GitHubBuildTriggerType = exports.GitHubBuildTriggerRunStatus = exports.GitHubBuildTriggerExecutionBehavior = exports.GitHubAppInstallationStatus = exports.GitHubAppInstallationAccountType = exports.GitHubAppEnvironment = exports.FingerprintSourceType = exports.Feature = exports.Experiment = exports.ExitInterviewOutcome = exports.ExitInterviewMessageRole = exports.EnvironmentVariableVisibility = exports.EnvironmentVariableScope = exports.EnvironmentSecretType = exports.EntityTypeName = exports.EchoVersionSource = exports.EchoTurnCompletionStatus = exports.EchoProjectVisibility = exports.EchoProjectUploadSessionType = exports.EchoProjectIconSource = exports.EchoMessageRole = exports.EchoMessagePartType = exports.EchoChatState = exports.EchoChangeType = exports.EchoBuildStatus = exports.EchoAgentType = exports.EasTotalPlanEnablementUnit = exports.EasServiceMetric = exports.EasService = exports.EasBuildWaiverType = exports.EasBuildDeprecationInfoType = exports.EasBuildBillingResourceClass = exports.DistributionType = exports.DeviceRunSessionType = exports.DeviceRunSessionStatus = exports.DashboardViewPin = exports.CustomDomainStatus = exports.CustomDomainDnsRecordType = exports.CrashSampleFor = void 0;
11
- exports.WorkflowDeviceTestCaseSortDirection = exports.WorkflowDeviceTestCaseInsightsTimeSeriesGranularity = exports.WorkflowArtifactStorageType = exports.WorkerLoggerLevel = exports.WorkerDeploymentLogLevel = exports.WorkerDeploymentCrashKind = exports.WebhookType = exports.UserSpecifiedAccountUsage = exports.UserEntityTypeName = exports.UserAgentPlatform = exports.UserAgentOs = exports.UserAgentBrowser = exports.UsageMetricsGranularity = exports.UsageMetricType = exports.UploadSessionType = exports.UpdatesTimelineItemType = exports.UpdateDiffReceiptStateValue = exports.UpdateDiffReceiptOrderByField = exports.UpdateDiffReceiptOrderByDirection = exports.TargetEntityMutationType = exports.SubmissionStatus = exports.SubmissionPriority = exports.SubmissionArchiveSourceType = exports.SubmissionAndroidReleaseStatus = exports.SubmissionAndroidArchiveType = exports.StatuspageServiceStatus = exports.StatuspageServiceName = exports.StatuspageIncidentStatus = exports.StatuspageIncidentImpact = exports.StandardOffer = exports.SecondFactorMethod = exports.Role = exports.ResponseType = exports.ResponseStatusType = exports.ResponseCacheStatus = exports.ResourceClassExperiment = exports.RequestsOrderByField = exports.RequestsOrderByDirection = exports.RequestMethod = exports.ProjectArchiveSourceType = exports.PostHogRegion = exports.Permission = exports.Order = exports.OnboardingEnvironment = exports.OnboardingDeviceType = exports.OfferType = exports.OAuthProvider = exports.NotificationType = exports.NotificationEvent = exports.LocalBuildArchiveSourceType = void 0;
12
- exports.WorkflowsInsightsRunsOverTimeGranularity = exports.WorkflowsInsightsExportFormat = exports.WorkflowRunTriggerEventType = exports.WorkflowRunStatus = exports.WorkflowProjectSourceType = exports.WorkflowJobType = exports.WorkflowJobStatus = exports.WorkflowJobReviewDecision = exports.WorkflowDeviceTestCaseStatusFilter = exports.WorkflowDeviceTestCaseStatus = exports.WorkflowDeviceTestCaseStatSortField = void 0;
9
+ exports.BuildStatus = exports.BuildRetryDisabledReason = exports.BuildResourceClass = exports.BuildPriority = exports.BuildPhase = exports.BuildMode = exports.BuildLimitThresholdExceededMetadataType = exports.BuildIosEnterpriseProvisioning = exports.BuildCredentialsSource = exports.BuildAnnotationType = exports.BackgroundJobState = exports.BackgroundJobResultType = exports.AuthProviderIdentifier = exports.AuthProtocolType = exports.AuditLogsExportFormat = exports.AssetMetadataStatus = exports.AssetMapSourceType = exports.AppsFilter = exports.AppleTeamType = exports.AppleDeviceClass = exports.AppUploadSessionType = exports.AppStoreConnectWorkflowConnectionStatus = exports.AppStoreConnectUserRole = exports.AppStoreConnectBuildUploadState = exports.AppStoreConnectBuildProcessingState = exports.AppSort = exports.AppProfileImageWidth = exports.AppPrivacy = exports.AppPlatform = exports.AppObserveUpdatesOrderByField = exports.AppObserveUpdatesOrderByDirection = exports.AppObservePropertyType = exports.AppObservePlatform = exports.AppObserveNavigationRoutesOrderByField = exports.AppObserveEventsOrderByField = exports.AppObserveEventsOrderByDirection = exports.AppObserveErrorSeverity = exports.AppObserveErrorGroupsOrderBy = exports.AppObserveErrorBreakdownDimension = exports.AppObserveCustomEventNamesOrderByField = exports.AppObserveCustomEventNamesOrderByDirection = exports.AppObserveCustomEventListOrderByField = exports.AppInternalDistributionBuildPrivacy = exports.AndroidKeystoreType = exports.AndroidFcmVersion = exports.AndroidBuildType = exports.ActivityTimelineProjectActivityType = exports.AccountUploadSessionType = exports.AccountMemberType = exports.AccountAppsSortByField = void 0;
10
+ exports.IosManagedBuildType = exports.IosDistributionType = exports.IosBuildType = exports.InvoiceDiscountType = exports.InsightsFilterType = exports.GitHubJobRunTriggerType = exports.GitHubJobRunTriggerRunStatus = exports.GitHubJobRunJobType = exports.GitHubBuildTriggerType = exports.GitHubBuildTriggerRunStatus = exports.GitHubBuildTriggerExecutionBehavior = exports.GitHubAppInstallationStatus = exports.GitHubAppInstallationAccountType = exports.GitHubAppEnvironment = exports.FingerprintSourceType = exports.Feature = exports.Experiment = exports.ExitInterviewOutcome = exports.ExitInterviewMessageRole = exports.EnvironmentVariableVisibility = exports.EnvironmentVariableScope = exports.EnvironmentSecretType = exports.EntityTypeName = exports.EchoVersionSource = exports.EchoTurnCompletionStatus = exports.EchoProjectVisibility = exports.EchoProjectUploadSessionType = exports.EchoProjectIconSource = exports.EchoMessageRole = exports.EchoMessagePartType = exports.EchoChatState = exports.EchoChangeType = exports.EchoBuildStatus = exports.EchoAgentType = exports.EasTotalPlanEnablementUnit = exports.EasServiceMetric = exports.EasService = exports.EasBuildWaiverType = exports.EasBuildDeprecationInfoType = exports.EasBuildBillingResourceClass = exports.DistributionType = exports.DeviceRunSessionType = exports.DeviceRunSessionStatus = exports.DashboardViewPin = exports.CustomDomainStatus = exports.CustomDomainDnsRecordType = exports.CrashSampleFor = exports.ContinentCode = exports.BuildWorkflow = exports.BuildTrigger = void 0;
11
+ exports.WorkerDeploymentLogLevel = exports.WorkerDeploymentCrashKind = exports.WebhookType = exports.UserSpecifiedAccountUsage = exports.UserEntityTypeName = exports.UserAgentPlatform = exports.UserAgentOs = exports.UserAgentBrowser = exports.UsageMetricsGranularity = exports.UsageMetricType = exports.UploadSessionType = exports.UpdatesTimelineItemType = exports.UpdateDiffReceiptStateValue = exports.UpdateDiffReceiptOrderByField = exports.UpdateDiffReceiptOrderByDirection = exports.TargetEntityMutationType = exports.SubmissionStatus = exports.SubmissionPriority = exports.SubmissionArchiveSourceType = exports.SubmissionAndroidReleaseStatus = exports.SubmissionAndroidArchiveType = exports.StatuspageServiceStatus = exports.StatuspageServiceName = exports.StatuspageIncidentStatus = exports.StatuspageIncidentImpact = exports.StandardOffer = exports.SecondFactorMethod = exports.Role = exports.ResponseType = exports.ResponseStatusType = exports.ResponseCacheStatus = exports.ResourceClassExperiment = exports.RequestsOrderByField = exports.RequestsOrderByDirection = exports.RequestMethod = exports.ProjectArchiveSourceType = exports.PostHogRegion = exports.PostHogDeepLinkPurpose = exports.Permission = exports.Order = exports.OnboardingEnvironment = exports.OnboardingDeviceType = exports.OfferType = exports.OAuthProvider = exports.NotificationType = exports.NotificationEvent = exports.LocalBuildArchiveSourceType = exports.JobRunStatus = exports.JobRunPriority = exports.IosSchemeBuildConfiguration = void 0;
12
+ exports.WorkflowsInsightsRunsOverTimeGranularity = exports.WorkflowsInsightsExportFormat = exports.WorkflowRunTriggerEventType = exports.WorkflowRunStatus = exports.WorkflowProjectSourceType = exports.WorkflowJobType = exports.WorkflowJobStatus = exports.WorkflowJobReviewDecision = exports.WorkflowDispatchInputType = exports.WorkflowDeviceTestCaseStatusFilter = exports.WorkflowDeviceTestCaseStatus = exports.WorkflowDeviceTestCaseStatSortField = exports.WorkflowDeviceTestCaseSortDirection = exports.WorkflowDeviceTestCaseInsightsTimeSeriesGranularity = exports.WorkflowArtifactStorageType = exports.WorkerLoggerLevel = void 0;
13
13
  var AccountAppsSortByField;
14
14
  (function (AccountAppsSortByField) {
15
15
  AccountAppsSortByField["LatestActivityTime"] = "LATEST_ACTIVITY_TIME";
@@ -67,6 +67,10 @@ var AppInternalDistributionBuildPrivacy;
67
67
  AppInternalDistributionBuildPrivacy["Private"] = "PRIVATE";
68
68
  AppInternalDistributionBuildPrivacy["Public"] = "PUBLIC";
69
69
  })(AppInternalDistributionBuildPrivacy || (exports.AppInternalDistributionBuildPrivacy = AppInternalDistributionBuildPrivacy = {}));
70
+ var AppObserveCustomEventListOrderByField;
71
+ (function (AppObserveCustomEventListOrderByField) {
72
+ AppObserveCustomEventListOrderByField["Timestamp"] = "TIMESTAMP";
73
+ })(AppObserveCustomEventListOrderByField || (exports.AppObserveCustomEventListOrderByField = AppObserveCustomEventListOrderByField = {}));
70
74
  var AppObserveCustomEventNamesOrderByDirection;
71
75
  (function (AppObserveCustomEventNamesOrderByDirection) {
72
76
  AppObserveCustomEventNamesOrderByDirection["Asc"] = "ASC";
@@ -166,6 +170,20 @@ var AppSort;
166
170
  /** Sort by highest trendScore */
167
171
  AppSort["Viewed"] = "VIEWED";
168
172
  })(AppSort || (exports.AppSort = AppSort = {}));
173
+ var AppStoreConnectBuildProcessingState;
174
+ (function (AppStoreConnectBuildProcessingState) {
175
+ AppStoreConnectBuildProcessingState["Failed"] = "FAILED";
176
+ AppStoreConnectBuildProcessingState["Invalid"] = "INVALID";
177
+ AppStoreConnectBuildProcessingState["Processing"] = "PROCESSING";
178
+ AppStoreConnectBuildProcessingState["Valid"] = "VALID";
179
+ })(AppStoreConnectBuildProcessingState || (exports.AppStoreConnectBuildProcessingState = AppStoreConnectBuildProcessingState = {}));
180
+ var AppStoreConnectBuildUploadState;
181
+ (function (AppStoreConnectBuildUploadState) {
182
+ AppStoreConnectBuildUploadState["AwaitingUpload"] = "AWAITING_UPLOAD";
183
+ AppStoreConnectBuildUploadState["Complete"] = "COMPLETE";
184
+ AppStoreConnectBuildUploadState["Failed"] = "FAILED";
185
+ AppStoreConnectBuildUploadState["Processing"] = "PROCESSING";
186
+ })(AppStoreConnectBuildUploadState || (exports.AppStoreConnectBuildUploadState = AppStoreConnectBuildUploadState = {}));
169
187
  var AppStoreConnectUserRole;
170
188
  (function (AppStoreConnectUserRole) {
171
189
  AppStoreConnectUserRole["AccessToReports"] = "ACCESS_TO_REPORTS";
@@ -475,6 +493,7 @@ var EasService;
475
493
  EasService["Builds"] = "BUILDS";
476
494
  EasService["Jobs"] = "JOBS";
477
495
  EasService["Mcp"] = "MCP";
496
+ EasService["Observe"] = "OBSERVE";
478
497
  EasService["Updates"] = "UPDATES";
479
498
  })(EasService || (exports.EasService = EasService = {}));
480
499
  var EasServiceMetric;
@@ -486,6 +505,7 @@ var EasServiceMetric;
486
505
  EasServiceMetric["LocalBuilds"] = "LOCAL_BUILDS";
487
506
  EasServiceMetric["ManifestRequests"] = "MANIFEST_REQUESTS";
488
507
  EasServiceMetric["McpRequests"] = "MCP_REQUESTS";
508
+ EasServiceMetric["ObserveEvents"] = "OBSERVE_EVENTS";
489
509
  EasServiceMetric["RunTime"] = "RUN_TIME";
490
510
  EasServiceMetric["UniqueUpdaters"] = "UNIQUE_UPDATERS";
491
511
  EasServiceMetric["UniqueUsers"] = "UNIQUE_USERS";
@@ -495,6 +515,7 @@ var EasTotalPlanEnablementUnit;
495
515
  EasTotalPlanEnablementUnit["Build"] = "BUILD";
496
516
  EasTotalPlanEnablementUnit["Byte"] = "BYTE";
497
517
  EasTotalPlanEnablementUnit["Concurrency"] = "CONCURRENCY";
518
+ EasTotalPlanEnablementUnit["Event"] = "EVENT";
498
519
  EasTotalPlanEnablementUnit["Request"] = "REQUEST";
499
520
  EasTotalPlanEnablementUnit["Updater"] = "UPDATER";
500
521
  EasTotalPlanEnablementUnit["User"] = "USER";
@@ -806,6 +827,13 @@ var Permission;
806
827
  Permission["Publish"] = "PUBLISH";
807
828
  Permission["View"] = "VIEW";
808
829
  })(Permission || (exports.Permission = Permission = {}));
830
+ /** Which EAS surface a deep link was opened from; PostHog records it as an analytics label. */
831
+ var PostHogDeepLinkPurpose;
832
+ (function (PostHogDeepLinkPurpose) {
833
+ PostHogDeepLinkPurpose["Dashboard"] = "DASHBOARD";
834
+ PostHogDeepLinkPurpose["Observability"] = "OBSERVABILITY";
835
+ PostHogDeepLinkPurpose["Project"] = "PROJECT";
836
+ })(PostHogDeepLinkPurpose || (exports.PostHogDeepLinkPurpose = PostHogDeepLinkPurpose = {}));
809
837
  var PostHogRegion;
810
838
  (function (PostHogRegion) {
811
839
  PostHogRegion["Eu"] = "EU";
@@ -1019,6 +1047,7 @@ var UsageMetricType;
1019
1047
  UsageMetricType["Bandwidth"] = "BANDWIDTH";
1020
1048
  UsageMetricType["Build"] = "BUILD";
1021
1049
  UsageMetricType["Credit"] = "CREDIT";
1050
+ UsageMetricType["Event"] = "EVENT";
1022
1051
  UsageMetricType["Minute"] = "MINUTE";
1023
1052
  UsageMetricType["Request"] = "REQUEST";
1024
1053
  UsageMetricType["Update"] = "UPDATE";
@@ -1162,6 +1191,14 @@ var WorkflowDeviceTestCaseStatusFilter;
1162
1191
  WorkflowDeviceTestCaseStatusFilter["Flaky"] = "FLAKY";
1163
1192
  WorkflowDeviceTestCaseStatusFilter["PassedClean"] = "PASSED_CLEAN";
1164
1193
  })(WorkflowDeviceTestCaseStatusFilter || (exports.WorkflowDeviceTestCaseStatusFilter = WorkflowDeviceTestCaseStatusFilter = {}));
1194
+ var WorkflowDispatchInputType;
1195
+ (function (WorkflowDispatchInputType) {
1196
+ WorkflowDispatchInputType["Boolean"] = "BOOLEAN";
1197
+ WorkflowDispatchInputType["Choice"] = "CHOICE";
1198
+ WorkflowDispatchInputType["Environment"] = "ENVIRONMENT";
1199
+ WorkflowDispatchInputType["Number"] = "NUMBER";
1200
+ WorkflowDispatchInputType["String"] = "STRING";
1201
+ })(WorkflowDispatchInputType || (exports.WorkflowDispatchInputType = WorkflowDispatchInputType = {}));
1165
1202
  var WorkflowJobReviewDecision;
1166
1203
  (function (WorkflowJobReviewDecision) {
1167
1204
  WorkflowJobReviewDecision["Approved"] = "APPROVED";
@@ -1,7 +1,9 @@
1
1
  import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
2
+ import { BackgroundJobReceiptDataFragment } from '../generated';
2
3
  export declare const AppMutation: {
3
4
  createAppAsync(graphqlClient: ExpoGraphqlClient, appInput: {
4
5
  accountId: string;
5
6
  projectName: string;
6
7
  }): Promise<string>;
8
+ scheduleAppDeletionAsync(graphqlClient: ExpoGraphqlClient, appId: string): Promise<BackgroundJobReceiptDataFragment>;
7
9
  };
@@ -5,6 +5,7 @@ const tslib_1 = require("tslib");
5
5
  const assert_1 = tslib_1.__importDefault(require("assert"));
6
6
  const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
7
7
  const client_1 = require("../client");
8
+ const BackgroundJobReceipt_1 = require("../types/BackgroundJobReceipt");
8
9
  exports.AppMutation = {
9
10
  async createAppAsync(graphqlClient, appInput) {
10
11
  const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
@@ -24,4 +25,22 @@ exports.AppMutation = {
24
25
  (0, assert_1.default)(appId, 'App ID must be defined');
25
26
  return appId;
26
27
  },
28
+ async scheduleAppDeletionAsync(graphqlClient, appId) {
29
+ const result = await (0, client_1.withErrorHandlingAsync)(graphqlClient
30
+ .mutation((0, graphql_tag_1.default) `
31
+ mutation ScheduleAppDeletion($appId: ID!) {
32
+ app {
33
+ scheduleAppDeletion(appId: $appId) {
34
+ id
35
+ ...BackgroundJobReceiptData
36
+ }
37
+ }
38
+ }
39
+ ${BackgroundJobReceipt_1.BackgroundJobReceiptNode}
40
+ `, { appId })
41
+ .toPromise());
42
+ const receipt = result.app?.scheduleAppDeletion;
43
+ (0, assert_1.default)(receipt, 'Background job receipt must be defined');
44
+ return receipt;
45
+ },
27
46
  };
@@ -1,8 +1,9 @@
1
1
  import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
2
- import { CreatePostHogAccountRequestInput, SetupPostHogProjectInput } from '../generated';
2
+ import { CreatePostHogAccountRequestInput, CreatePostHogDeepLinkInput, SetupPostHogProjectInput } from '../generated';
3
3
  import { PostHogProjectData, StartPostHogConnectionResult } from '../types/PostHogConnection';
4
4
  export declare const PostHogMutation: {
5
5
  startPostHogConnectionAsync(graphqlClient: ExpoGraphqlClient, input: CreatePostHogAccountRequestInput): Promise<StartPostHogConnectionResult>;
6
6
  setupPostHogProjectAsync(graphqlClient: ExpoGraphqlClient, input: SetupPostHogProjectInput): Promise<PostHogProjectData>;
7
7
  deletePostHogProjectAsync(graphqlClient: ExpoGraphqlClient, id: string): Promise<string>;
8
+ createPostHogDeepLinkAsync(graphqlClient: ExpoGraphqlClient, input: CreatePostHogDeepLinkInput): Promise<string>;
8
9
  };
@@ -58,4 +58,18 @@ exports.PostHogMutation = {
58
58
  .toPromise());
59
59
  return data.posthogProject.deletePostHogProject;
60
60
  },
61
+ async createPostHogDeepLinkAsync(graphqlClient, input) {
62
+ const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
63
+ .mutation((0, graphql_tag_1.default) `
64
+ mutation CreatePostHogDeepLink($input: CreatePostHogDeepLinkInput!) {
65
+ posthogOrganizationConnection {
66
+ createPostHogDeepLink(input: $input) {
67
+ url
68
+ }
69
+ }
70
+ }
71
+ `, { input })
72
+ .toPromise());
73
+ return data.posthogOrganizationConnection.createPostHogDeepLink.url;
74
+ },
61
75
  };
@@ -14,6 +14,11 @@ exports.DeviceRunSessionQuery = {
14
14
  id
15
15
  status
16
16
  type
17
+ platform
18
+ createdAt
19
+ startedAt
20
+ finishedAt
21
+ updatedAt
17
22
  app {
18
23
  id
19
24
  slug
@@ -22,6 +27,16 @@ exports.DeviceRunSessionQuery = {
22
27
  name
23
28
  }
24
29
  }
30
+ artifacts {
31
+ id
32
+ name
33
+ filename
34
+ downloadUrl
35
+ fileSizeBytes
36
+ metadata
37
+ createdAt
38
+ updatedAt
39
+ }
25
40
  remoteConfig {
26
41
  __typename
27
42
  ... on AgentDeviceRunSessionRemoteConfig {
@@ -23,16 +23,6 @@ exports.UserQuery = {
23
23
  id
24
24
  ...AccountFragment
25
25
  }
26
- preferences {
27
- onboarding {
28
- appId
29
- platform
30
- deviceType
31
- environment
32
- isCLIDone
33
- lastUsed
34
- }
35
- }
36
26
  }
37
27
  ... on Robot {
38
28
  firstName
@@ -19,6 +19,7 @@ exports.WorkflowRunQuery = {
19
19
  isLatest
20
20
  isBeta
21
21
  isDeprecated
22
+ sourceIpaUrl
22
23
  }
23
24
  }
24
25
  }
@@ -17,8 +17,8 @@ function buildJsonOutput(action, metadata) {
17
17
  ? {
18
18
  id: link.id,
19
19
  ascAppIdentifier: link.ascAppIdentifier,
20
- name: link.remoteAppStoreConnectApp.name ?? null,
21
- bundleIdentifier: link.remoteAppStoreConnectApp.bundleIdentifier ?? null,
20
+ name: link.remoteAppStoreConnectApp?.name ?? null,
21
+ bundleIdentifier: link.remoteAppStoreConnectApp?.bundleIdentifier ?? null,
22
22
  appleUrl: getAppleAppUrl(link.ascAppIdentifier),
23
23
  }
24
24
  : null,
@@ -46,8 +46,10 @@ function formatAscAppLinkStatus(metadata) {
46
46
  ` ASC App ID: ${chalk_1.default.bold(link.ascAppIdentifier)}`,
47
47
  ];
48
48
  const remote = link.remoteAppStoreConnectApp;
49
- lines.push(` Name: ${remote.name}`);
50
- lines.push(` Bundle ID: ${remote.bundleIdentifier}`);
49
+ if (remote) {
50
+ lines.push(` Name: ${remote.name}`);
51
+ lines.push(` Bundle ID: ${remote.bundleIdentifier}`);
52
+ }
51
53
  lines.push(` Apple URL: ${getAppleAppUrl(link.ascAppIdentifier)}`);
52
54
  return lines.join('\n');
53
55
  }
@@ -1,5 +1,5 @@
1
- export declare const METRIC_ALIASES: Record<string, string>;
2
1
  export declare const NAVIGATION_METRIC_ALIASES: Record<string, string>;
2
+ export declare const METRIC_ALIASES: Record<string, string>;
3
3
  export declare const METRIC_SHORT_NAMES: Record<string, string>;
4
4
  export declare function resolveMetricName(input: string): string;
5
5
  export declare function resolveNavigationMetricName(input: string): string;
@@ -1,11 +1,17 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.METRIC_SHORT_NAMES = exports.NAVIGATION_METRIC_ALIASES = exports.METRIC_ALIASES = void 0;
3
+ exports.METRIC_SHORT_NAMES = exports.METRIC_ALIASES = exports.NAVIGATION_METRIC_ALIASES = void 0;
4
4
  exports.resolveMetricName = resolveMetricName;
5
5
  exports.resolveNavigationMetricName = resolveNavigationMetricName;
6
6
  exports.getMetricDisplayName = getMetricDisplayName;
7
7
  const errors_1 = require("../commandUtils/errors");
8
+ exports.NAVIGATION_METRIC_ALIASES = {
9
+ nav_cold_ttr: 'expo.navigation.cold_ttr',
10
+ nav_warm_ttr: 'expo.navigation.warm_ttr',
11
+ nav_tti: 'expo.navigation.tti',
12
+ };
8
13
  exports.METRIC_ALIASES = {
14
+ ...exports.NAVIGATION_METRIC_ALIASES,
9
15
  tti: 'expo.app_startup.tti',
10
16
  ttr: 'expo.app_startup.ttr',
11
17
  cold_launch: 'expo.app_startup.cold_launch_time',
@@ -13,11 +19,6 @@ exports.METRIC_ALIASES = {
13
19
  bundle_load: 'expo.app_startup.bundle_load_time',
14
20
  update_download: 'expo.updates.download_time',
15
21
  };
16
- exports.NAVIGATION_METRIC_ALIASES = {
17
- cold_ttr: 'expo.navigation.cold_ttr',
18
- warm_ttr: 'expo.navigation.warm_ttr',
19
- nav_tti: 'expo.navigation.tti',
20
- };
21
22
  const KNOWN_FULL_NAMES = new Set(Object.values(exports.METRIC_ALIASES));
22
23
  const KNOWN_FULL_NAVIGATION_NAMES = new Set(Object.values(exports.NAVIGATION_METRIC_ALIASES));
23
24
  exports.METRIC_SHORT_NAMES = {
@@ -3,13 +3,14 @@ import { GradleBuildContext } from './gradle';
3
3
  import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
4
4
  import { Client } from '../../vcs/vcs';
5
5
  export declare const INVALID_APPLICATION_ID_MESSAGE = "Invalid format of Android applicationId. Only alphanumeric characters, '.' and '_' are allowed, and each '.' must be followed by a letter.";
6
- export declare function ensureApplicationIdIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, }: {
6
+ export declare function ensureApplicationIdIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, autoSelectDefault, }: {
7
7
  graphqlClient: ExpoGraphqlClient;
8
8
  projectDir: string;
9
9
  projectId: string;
10
10
  exp: ExpoConfig;
11
11
  vcsClient: Client;
12
12
  nonInteractive: boolean;
13
+ autoSelectDefault?: boolean;
13
14
  }): Promise<string>;
14
15
  export declare class AmbiguousApplicationIdError extends Error {
15
16
  constructor(message?: string);
@@ -22,7 +22,7 @@ const projectUtils_1 = require("../../project/projectUtils");
22
22
  const prompts_1 = require("../../prompts");
23
23
  const workflow_1 = require("../workflow");
24
24
  exports.INVALID_APPLICATION_ID_MESSAGE = `Invalid format of Android applicationId. Only alphanumeric characters, '.' and '_' are allowed, and each '.' must be followed by a letter.`;
25
- async function ensureApplicationIdIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, }) {
25
+ async function ensureApplicationIdIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, autoSelectDefault = false, }) {
26
26
  const workflow = await (0, workflow_1.resolveWorkflowAsync)(projectDir, eas_build_job_1.Platform.ANDROID, vcsClient);
27
27
  (0, assert_1.default)(workflow === eas_build_job_1.Workflow.MANAGED, 'This function should be called only for managed projects');
28
28
  try {
@@ -37,6 +37,7 @@ async function ensureApplicationIdIsDefinedForManagedProjectAsync({ graphqlClien
37
37
  projectId,
38
38
  exp,
39
39
  nonInteractive,
40
+ autoSelectDefault,
40
41
  });
41
42
  }
42
43
  }
@@ -93,7 +94,7 @@ async function getApplicationIdAsync(projectDir, exp, vcsClient, gradleContext)
93
94
  }
94
95
  }
95
96
  }
96
- async function configureApplicationIdAsync({ graphqlClient, projectDir, projectId, exp, nonInteractive, }) {
97
+ async function configureApplicationIdAsync({ graphqlClient, projectDir, projectId, exp, nonInteractive, autoSelectDefault = false, }) {
97
98
  if (nonInteractive) {
98
99
  throw new Error(`The "android.package" is required to be set in app config when running in non-interactive mode. ${(0, log_1.learnMore)('https://docs.expo.dev/versions/latest/config/app/#package')}`);
99
100
  }
@@ -103,16 +104,23 @@ async function configureApplicationIdAsync({ graphqlClient, projectDir, projectI
103
104
  throw new Error(`"android.package" is not defined in your app.config.js and we can't update this file programmatically. Add the value on your own and run this command again.`);
104
105
  }
105
106
  (0, assert_1.default)(paths.staticConfigPath, 'app.json must exist');
106
- log_1.default.addNewLineIfNone();
107
- log_1.default.log(`${chalk_1.default.bold(`📝 Android application id`)} ${chalk_1.default.dim((0, log_1.learnMore)('https://expo.fyi/android-package'))}`);
108
107
  const suggestedAndroidApplicationId = await getSuggestedApplicationIdAsync(graphqlClient, exp, projectId);
109
- const { packageName } = await (0, prompts_1.promptAsync)({
110
- name: 'packageName',
111
- type: 'text',
112
- message: `What would you like your Android application id to be?`,
113
- initial: suggestedAndroidApplicationId,
114
- validate: value => (isApplicationIdValid(value) ? true : exports.INVALID_APPLICATION_ID_MESSAGE),
115
- });
108
+ let packageName;
109
+ if (autoSelectDefault && suggestedAndroidApplicationId) {
110
+ packageName = suggestedAndroidApplicationId;
111
+ log_1.default.withTick(`Set "android.package" to ${chalk_1.default.bold(packageName)} (modified app.json)`);
112
+ }
113
+ else {
114
+ log_1.default.addNewLineIfNone();
115
+ log_1.default.log(`${chalk_1.default.bold(`📝 Android application id`)} ${chalk_1.default.dim((0, log_1.learnMore)('https://expo.fyi/android-package'))}`);
116
+ ({ packageName } = await (0, prompts_1.promptAsync)({
117
+ name: 'packageName',
118
+ type: 'text',
119
+ message: `What would you like your Android application id to be?`,
120
+ initial: suggestedAndroidApplicationId,
121
+ validate: value => (isApplicationIdValid(value) ? true : exports.INVALID_APPLICATION_ID_MESSAGE),
122
+ }));
123
+ }
116
124
  const rawStaticConfig = (0, appJson_1.readAppJson)(paths.staticConfigPath);
117
125
  rawStaticConfig.expo = {
118
126
  ...rawStaticConfig.expo,
@@ -2,13 +2,14 @@ import { ExpoConfig } from '@expo/config';
2
2
  import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
3
3
  import { Client } from '../../vcs/vcs';
4
4
  export declare const INVALID_BUNDLE_IDENTIFIER_MESSAGE = "Invalid format of iOS bundle identifier. Only alphanumeric characters, '.' and '-' are allowed, and each '.' must be followed by a letter.";
5
- export declare function ensureBundleIdentifierIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, }: {
5
+ export declare function ensureBundleIdentifierIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, autoSelectDefault, }: {
6
6
  graphqlClient: ExpoGraphqlClient;
7
7
  projectDir: string;
8
8
  projectId: string;
9
9
  exp: ExpoConfig;
10
10
  vcsClient: Client;
11
11
  nonInteractive: boolean;
12
+ autoSelectDefault?: boolean;
12
13
  }): Promise<string>;
13
14
  export declare class AmbiguousBundleIdentifierError extends Error {
14
15
  constructor(message?: string);
@@ -20,7 +20,7 @@ const prompts_1 = require("../../prompts");
20
20
  const projectUtils_1 = require("../projectUtils");
21
21
  const workflow_1 = require("../workflow");
22
22
  exports.INVALID_BUNDLE_IDENTIFIER_MESSAGE = `Invalid format of iOS bundle identifier. Only alphanumeric characters, '.' and '-' are allowed, and each '.' must be followed by a letter.`;
23
- async function ensureBundleIdentifierIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, }) {
23
+ async function ensureBundleIdentifierIsDefinedForManagedProjectAsync({ graphqlClient, projectDir, projectId, exp, vcsClient, nonInteractive, autoSelectDefault = false, }) {
24
24
  const workflow = await (0, workflow_1.resolveWorkflowAsync)(projectDir, eas_build_job_1.Platform.IOS, vcsClient);
25
25
  (0, assert_1.default)(workflow === eas_build_job_1.Workflow.MANAGED, 'This function should be called only for managed projects');
26
26
  try {
@@ -33,6 +33,7 @@ async function ensureBundleIdentifierIsDefinedForManagedProjectAsync({ graphqlCl
33
33
  exp,
34
34
  projectId,
35
35
  nonInteractive,
36
+ autoSelectDefault,
36
37
  });
37
38
  }
38
39
  }
@@ -82,7 +83,7 @@ async function getBundleIdentifierAsync(projectDir, exp, vcsClient, xcodeContext
82
83
  }
83
84
  }
84
85
  }
85
- async function configureBundleIdentifierAsync({ graphqlClient, projectDir, projectId, exp, nonInteractive, }) {
86
+ async function configureBundleIdentifierAsync({ graphqlClient, projectDir, projectId, exp, nonInteractive, autoSelectDefault = false, }) {
86
87
  if (nonInteractive) {
87
88
  throw new Error(`The "ios.bundleIdentifier" is required to be set in app config when running in non-interactive mode. ${(0, log_1.learnMore)('https://docs.expo.dev/versions/latest/config/app/#bundleidentifier')}`);
88
89
  }
@@ -92,16 +93,23 @@ async function configureBundleIdentifierAsync({ graphqlClient, projectDir, proje
92
93
  throw new Error(`"ios.bundleIdentifier" is not defined in your app.config.js and we can't update this file programmatically. Add the value on your own and run this command again.`);
93
94
  }
94
95
  (0, assert_1.default)(paths.staticConfigPath, 'app.json must exist');
95
- log_1.default.addNewLineIfNone();
96
- log_1.default.log(`${chalk_1.default.bold(`📝 iOS Bundle Identifier`)} ${chalk_1.default.dim((0, log_1.learnMore)('https://expo.fyi/bundle-identifier'))}`);
97
96
  const suggestedBundleIdentifier = await getSuggestedBundleIdentifierAsync(graphqlClient, exp, projectId);
98
- const { bundleIdentifier } = await (0, prompts_1.promptAsync)({
99
- name: 'bundleIdentifier',
100
- type: 'text',
101
- message: `What would you like your iOS bundle identifier to be?`,
102
- initial: suggestedBundleIdentifier,
103
- validate: value => (isBundleIdentifierValid(value) ? true : exports.INVALID_BUNDLE_IDENTIFIER_MESSAGE),
104
- });
97
+ let bundleIdentifier;
98
+ if (autoSelectDefault && suggestedBundleIdentifier) {
99
+ bundleIdentifier = suggestedBundleIdentifier;
100
+ log_1.default.withTick(`Set "ios.bundleIdentifier" to ${chalk_1.default.bold(bundleIdentifier)} (modified app.json)`);
101
+ }
102
+ else {
103
+ log_1.default.addNewLineIfNone();
104
+ log_1.default.log(`${chalk_1.default.bold(`📝 iOS Bundle Identifier`)} ${chalk_1.default.dim((0, log_1.learnMore)('https://expo.fyi/bundle-identifier'))}`);
105
+ ({ bundleIdentifier } = await (0, prompts_1.promptAsync)({
106
+ name: 'bundleIdentifier',
107
+ type: 'text',
108
+ message: `What would you like your iOS bundle identifier to be?`,
109
+ initial: suggestedBundleIdentifier,
110
+ validate: value => isBundleIdentifierValid(value) ? true : exports.INVALID_BUNDLE_IDENTIFIER_MESSAGE,
111
+ }));
112
+ }
105
113
  const rawStaticConfig = (0, appJson_1.readAppJson)(paths.staticConfigPath);
106
114
  rawStaticConfig.expo = {
107
115
  ...rawStaticConfig.expo,
@@ -0,0 +1,9 @@
1
+ import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
2
+ import { Actor } from '../user/User';
3
+ export type InitializeMethodOptions = {
4
+ force: boolean;
5
+ nonInteractive: boolean;
6
+ };
7
+ export declare function ensureOwnerSlugConsistencyAsync(graphqlClient: ExpoGraphqlClient, projectId: string, projectDir: string, { force, nonInteractive }: InitializeMethodOptions): Promise<void>;
8
+ export declare function initializeWithExplicitIDAsync(projectId: string, projectDir: string, { force, nonInteractive }: InitializeMethodOptions): Promise<void>;
9
+ export declare function initializeWithoutExplicitIDAsync(graphqlClient: ExpoGraphqlClient, actor: Actor, projectDir: string, { force, nonInteractive }: InitializeMethodOptions): Promise<string>;