eas-cli 16.6.1 → 16.7.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.
package/build/api.d.ts CHANGED
@@ -18,5 +18,5 @@ export declare class ApiV2Client {
18
18
  }
19
19
  export declare function getExpoApiBaseUrl(): string;
20
20
  export declare function getExpoWebsiteBaseUrl(): string;
21
- export declare function getEASUpdateURL(projectId: string): string;
21
+ export declare function getEASUpdateURL(projectId: string, manifestHostOverride: string | null): string;
22
22
  export {};
package/build/api.js CHANGED
@@ -90,7 +90,10 @@ function getExpoWebsiteBaseUrl() {
90
90
  }
91
91
  }
92
92
  exports.getExpoWebsiteBaseUrl = getExpoWebsiteBaseUrl;
93
- function getEASUpdateURL(projectId) {
93
+ function getEASUpdateURL(projectId, manifestHostOverride) {
94
+ if (manifestHostOverride) {
95
+ return new URL(projectId, `https://${manifestHostOverride}`).href;
96
+ }
94
97
  if (process.env.EXPO_STAGING) {
95
98
  return new URL(projectId, `https://staging-u.expo.dev`).href;
96
99
  }
@@ -12,7 +12,7 @@ const cacheDefaults = {
12
12
  paths: [],
13
13
  };
14
14
  async function prepareJobAsync(ctx, jobData) {
15
- const username = (0, projectUtils_1.getUsername)(ctx.exp, ctx.user);
15
+ const username = (0, projectUtils_1.getUsernameForBuildMetadataAndBuildJob)(ctx.user);
16
16
  const buildProfile = ctx.buildProfile;
17
17
  const projectRootDirectory = (0, slash_1.default)(path_1.default.relative(await ctx.vcsClient.getRootPathAsync(), ctx.projectDir)) || '.';
18
18
  const { credentials } = jobData;
@@ -13,7 +13,7 @@ const cacheDefaults = {
13
13
  paths: [],
14
14
  };
15
15
  async function prepareJobAsync(ctx, jobData) {
16
- const username = (0, projectUtils_1.getUsername)(ctx.exp, ctx.user);
16
+ const username = (0, projectUtils_1.getUsernameForBuildMetadataAndBuildJob)(ctx.user);
17
17
  const buildProfile = ctx.buildProfile;
18
18
  const projectRootDirectory = (0, slash_1.default)(path_1.default.relative(await ctx.vcsClient.getRootPathAsync(), ctx.projectDir)) || '.';
19
19
  const buildCredentials = {};
@@ -38,7 +38,7 @@ async function collectMetadataAsync(ctx, runtimeAndFingerprintMetadata) {
38
38
  isGitWorkingTreeDirty: ctx.localBuildOptions.localBuildMode === local_1.LocalBuildMode.INTERNAL
39
39
  ? false
40
40
  : await ctx.vcsClient.hasUncommittedChangesAsync(),
41
- username: (0, projectUtils_1.getUsername)(ctx.exp, ctx.user),
41
+ username: (0, projectUtils_1.getUsernameForBuildMetadataAndBuildJob)(ctx.user),
42
42
  message: ctx.message,
43
43
  ...(ctx.platform === eas_build_job_1.Platform.IOS && {
44
44
  iosEnterpriseProvisioning: resolveIosEnterpriseProvisioning(ctx),
@@ -121,6 +121,7 @@ async function runBuildAndSubmitAsync({ graphqlClient, analytics, vcsClient, pro
121
121
  getDynamicPrivateProjectConfigAsync,
122
122
  customBuildConfigMetadata: customBuildConfigMetadataByPlatform[platform],
123
123
  env,
124
+ easJsonAccessor,
124
125
  });
125
126
  if (maybeBuild) {
126
127
  startedBuilds.push({ build: maybeBuild, buildProfile });
@@ -215,7 +216,7 @@ async function runBuildAndSubmitAsync({ graphqlClient, analytics, vcsClient, pro
215
216
  };
216
217
  }
217
218
  exports.runBuildAndSubmitAsync = runBuildAndSubmitAsync;
218
- async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildProfile, easJsonCliConfig, actor, graphqlClient, analytics, vcsClient, getDynamicPrivateProjectConfigAsync, customBuildConfigMetadata, env, }) {
219
+ async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildProfile, easJsonCliConfig, actor, graphqlClient, analytics, vcsClient, getDynamicPrivateProjectConfigAsync, customBuildConfigMetadata, env, easJsonAccessor, }) {
219
220
  const buildCtx = await (0, createContext_1.createBuildContextAsync)({
220
221
  buildProfileName: buildProfile.profileName,
221
222
  resourceClassFlag: flags.resourceClass,
@@ -255,8 +256,10 @@ async function prepareAndStartBuildAsync({ projectDir, flags, moreBuilds, buildP
255
256
  nonInteractive: flags.nonInteractive,
256
257
  buildProfile,
257
258
  env: buildProfile.profile.env,
259
+ easJsonAccessor,
258
260
  });
259
- if ((0, projectUtils_1.isUsingEASUpdate)(buildCtx.exp, buildCtx.projectId)) {
261
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
262
+ if ((0, projectUtils_1.isUsingEASUpdate)(buildCtx.exp, buildCtx.projectId, easJsonUpdateConfig.manifestHostOverride ?? null)) {
260
263
  const doesChannelExist = await (0, queries_1.doesChannelExistAsync)(graphqlClient, {
261
264
  appId: buildCtx.projectId,
262
265
  channelName: buildProfile.profile.channel,
@@ -371,7 +374,7 @@ async function maybeDownloadAndRunSimulatorBuildsAsync(builds, flags, autoConfir
371
374
  }
372
375
  }
373
376
  }
374
- async function validateExpoUpdatesInstalledAsProjectDependencyAsync({ exp, projectId, projectDir, vcsClient, buildProfile, nonInteractive, sdkVersion, env, }) {
377
+ async function validateExpoUpdatesInstalledAsProjectDependencyAsync({ exp, projectId, projectDir, vcsClient, buildProfile, nonInteractive, sdkVersion, env, easJsonAccessor, }) {
375
378
  if ((0, projectUtils_1.isExpoUpdatesInstalledOrAvailable)(projectDir, sdkVersion)) {
376
379
  return;
377
380
  }
@@ -387,6 +390,7 @@ async function validateExpoUpdatesInstalledAsProjectDependencyAsync({ exp, proje
387
390
  message: `Would you like to install the "expo-updates" package and configure EAS Update now?`,
388
391
  });
389
392
  if (installExpoUpdates) {
393
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
390
394
  await (0, configure_2.ensureEASUpdateIsConfiguredAsync)({
391
395
  exp,
392
396
  projectId,
@@ -394,6 +398,7 @@ async function validateExpoUpdatesInstalledAsProjectDependencyAsync({ exp, proje
394
398
  platform: platform_1.RequestedPlatform.All,
395
399
  vcsClient,
396
400
  env,
401
+ manifestHostOverride: easJsonUpdateConfig.manifestHostOverride ?? null,
397
402
  });
398
403
  log_1.default.withTick('Installed expo-updates and configured EAS Update.');
399
404
  throw new Error('Command must be re-run to pick up new updates configuration.');
@@ -105,7 +105,7 @@ async function validateOrSetProjectIdAsync({ exp, graphqlClient, actor, options,
105
105
  throw new Error('This command must be run inside a project directory.');
106
106
  }
107
107
  log_1.default.warn('EAS project not configured.');
108
- const getAccountNameForEASProjectSync = (exp, user) => {
108
+ const getDefaultAccountNameForEASProject = (exp, user) => {
109
109
  if (exp.owner) {
110
110
  return exp.owner;
111
111
  }
@@ -115,11 +115,11 @@ async function validateOrSetProjectIdAsync({ exp, graphqlClient, actor, options,
115
115
  case 'SSOUser':
116
116
  return user.username;
117
117
  case 'Robot':
118
- throw new Error('The "owner" manifest property is required when using robot users. See: https://docs.expo.dev/versions/latest/config/app/#owner');
118
+ throw new Error('Must configure EAS project by running "eas init" before using a robot user to manage the project.');
119
119
  }
120
120
  };
121
121
  const projectId = await (0, fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync_1.fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync)(graphqlClient, {
122
- accountName: getAccountNameForEASProjectSync(exp, actor),
122
+ accountName: getDefaultAccountNameForEASProject(exp, actor),
123
123
  projectName: exp.slug,
124
124
  }, {
125
125
  nonInteractive: options.nonInteractive,
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const eas_build_job_1 = require("@expo/eas-build-job");
5
+ const eas_json_1 = require("@expo/eas-json");
5
6
  const core_1 = require("@oclif/core");
6
7
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
7
8
  const syncProjectConfiguration_1 = require("../../build/android/syncProjectConfiguration");
@@ -51,8 +52,12 @@ class BuildConfigure extends EasCommand_1.default {
51
52
  nonInteractive: false,
52
53
  vcsClient,
53
54
  });
54
- if (didCreateEasJson && (0, projectUtils_1.isUsingEASUpdate)(exp, projectId)) {
55
- await (0, configure_2.ensureEASUpdateIsConfiguredInEasJsonAsync)(projectDir);
55
+ if (didCreateEasJson) {
56
+ const easJsonAccessor = eas_json_1.EasJsonAccessor.fromProjectPath(projectDir);
57
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
58
+ if ((0, projectUtils_1.isUsingEASUpdate)(exp, projectId, easJsonUpdateConfig.manifestHostOverride ?? null)) {
59
+ await (0, configure_2.ensureEASUpdateIsConfiguredInEasJsonAsync)(projectDir);
60
+ }
56
61
  }
57
62
  // configure expo-updates
58
63
  if (expoUpdatesIsInstalled) {
@@ -283,7 +283,7 @@ async function configureProjectFromBareDefaultExpoTemplateAsync({ app, vcsClient
283
283
  const isSlugValidSegment = /^[^a-z]/.test(app.slug);
284
284
  const slugPrefix = isSlugValidSegment ? 'app' : '';
285
285
  const bundleIdentifier = `com.${userPrefix}${stripInvalidCharactersForBundleIdentifier(app.ownerAccount.name)}.${slugPrefix}${stripInvalidCharactersForBundleIdentifier(app.slug)}`;
286
- const updateUrl = (0, api_1.getEASUpdateURL)(app.id);
286
+ const updateUrl = (0, api_1.getEASUpdateURL)(app.id, /* manifestHostOverride */ null);
287
287
  const easBuildGitHubConfig = {
288
288
  android: {
289
289
  image: 'latest',
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
+ const eas_json_1 = require("@expo/eas-json");
4
5
  const core_1 = require("@oclif/core");
5
6
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
6
7
  const configure_1 = require("../../build/configure");
@@ -34,6 +35,8 @@ class UpdateConfigure extends EasCommand_1.default {
34
35
  });
35
36
  log_1.default.log('💡 The following process will configure your project to use EAS Update. These changes only apply to your local project files and you can safely revert them at any time.');
36
37
  await vcsClient.ensureRepoExistsAsync();
38
+ const easJsonAccessor = eas_json_1.EasJsonAccessor.fromProjectPath(projectDir);
39
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
37
40
  await (0, configure_2.ensureEASUpdateIsConfiguredAsync)({
38
41
  exp,
39
42
  projectId,
@@ -42,6 +45,7 @@ class UpdateConfigure extends EasCommand_1.default {
42
45
  vcsClient,
43
46
  env: undefined,
44
47
  forceNativeConfigSync: true,
48
+ manifestHostOverride: easJsonUpdateConfig.manifestHostOverride ?? null,
45
49
  });
46
50
  await (0, configure_2.ensureEASUpdateIsConfiguredInEasJsonAsync)(projectDir);
47
51
  log_1.default.addNewLineIfNone();
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  const eas_build_job_1 = require("@expo/eas-build-job");
5
+ const eas_json_1 = require("@expo/eas-json");
5
6
  const core_1 = require("@oclif/core");
6
7
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
7
8
  const nullthrows_1 = tslib_1.__importDefault(require("nullthrows"));
@@ -110,6 +111,8 @@ class UpdatePublish extends EasCommand_1.default {
110
111
  await (0, repository_1.ensureRepoIsCleanAsync)(vcsClient, nonInteractive);
111
112
  const { exp: expPossiblyWithoutEasUpdateConfigured, projectId, projectDir, } = await getDynamicPublicProjectConfigAsync();
112
113
  await (0, statuspageService_1.maybeWarnAboutEasOutagesAsync)(graphqlClient, [generated_1.StatuspageServiceName.EasUpdate]);
114
+ const easJsonAccessor = eas_json_1.EasJsonAccessor.fromProjectPath(projectDir);
115
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
113
116
  await (0, configure_1.ensureEASUpdateIsConfiguredAsync)({
114
117
  exp: expPossiblyWithoutEasUpdateConfigured,
115
118
  platform: requestedPlatform,
@@ -117,6 +120,7 @@ class UpdatePublish extends EasCommand_1.default {
117
120
  projectId,
118
121
  vcsClient,
119
122
  env: undefined,
123
+ manifestHostOverride: easJsonUpdateConfig.manifestHostOverride ?? null,
120
124
  });
121
125
  const { exp } = await getDynamicPublicProjectConfigAsync();
122
126
  const { exp: expPrivate } = await getDynamicPrivateProjectConfigAsync();
@@ -341,6 +345,8 @@ class UpdatePublish extends EasCommand_1.default {
341
345
  isGitWorkingTreeDirty,
342
346
  awaitingCodeSigningInfo: !!codeSigningInfo,
343
347
  environment: environment ?? null,
348
+ manifestHostOverride: easJsonUpdateConfig.manifestHostOverride ?? null,
349
+ assetHostOverride: easJsonUpdateConfig.assetHostOverride ?? null,
344
350
  };
345
351
  });
346
352
  let newUpdates;
@@ -12,6 +12,7 @@ export default class UpdateRepublish extends EasCommand {
12
12
  message: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
13
13
  platform: import("@oclif/core/lib/interfaces").OptionFlag<string>;
14
14
  'private-key-path': import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
15
+ 'rollout-percentage': import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
15
16
  };
16
17
  static contextDefinition: {
17
18
  loggedIn: import("../../commandUtils/context/LoggedInContextField").default;
@@ -56,6 +56,12 @@ class UpdateRepublish extends EasCommand_1.default {
56
56
  description: `File containing the PEM-encoded private key corresponding to the certificate in expo-updates' configuration. Defaults to a file named "private-key.pem" in the certificate's directory. Only relevant if you are using code signing: https://docs.expo.dev/eas-update/code-signing/`,
57
57
  required: false,
58
58
  }),
59
+ 'rollout-percentage': core_1.Flags.integer({
60
+ description: `Percentage of users this update should be immediately available to. Users not in the rollout will be served the previous latest update on the branch, even if that update is itself being rolled out. The specified number must be an integer between 1 and 100. When not specified, this defaults to 100.`,
61
+ required: false,
62
+ min: 0,
63
+ max: 100,
64
+ }),
59
65
  ...flags_1.EasNonInteractiveAndJsonFlags,
60
66
  };
61
67
  static contextDefinition = {
@@ -102,6 +108,7 @@ class UpdateRepublish extends EasCommand_1.default {
102
108
  updateMessage,
103
109
  codeSigningInfo,
104
110
  json: flags.json,
111
+ rolloutPercentage: flags.rolloutPercentage,
105
112
  });
106
113
  }
107
114
  sanitizeFlags(rawFlags) {
@@ -125,6 +132,7 @@ class UpdateRepublish extends EasCommand_1.default {
125
132
  platform,
126
133
  updateMessage: rawFlags.message,
127
134
  privateKeyPath,
135
+ rolloutPercentage: rawFlags['rollout-percentage'],
128
136
  json: rawFlags.json ?? false,
129
137
  nonInteractive,
130
138
  };
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
+ const eas_json_1 = require("@expo/eas-json");
4
5
  const core_1 = require("@oclif/core");
5
6
  const nullthrows_1 = tslib_1.__importDefault(require("nullthrows"));
6
7
  const queries_1 = require("../../branch/queries");
@@ -77,6 +78,8 @@ class UpdateRollBackToEmbedded extends EasCommand_1.default {
77
78
  }
78
79
  const { exp: expPossiblyWithoutEasUpdateConfigured, projectId, projectDir, } = await getDynamicPublicProjectConfigAsync();
79
80
  await (0, statuspageService_1.maybeWarnAboutEasOutagesAsync)(graphqlClient, [generated_1.StatuspageServiceName.EasUpdate]);
81
+ const easJsonAccessor = eas_json_1.EasJsonAccessor.fromProjectPath(projectDir);
82
+ const easJsonUpdateConfig = (await eas_json_1.EasJsonUtils.getUpdateConfigAsync(easJsonAccessor)) ?? {};
80
83
  await (0, configure_1.ensureEASUpdateIsConfiguredAsync)({
81
84
  exp: expPossiblyWithoutEasUpdateConfigured,
82
85
  platform: platformFlag,
@@ -84,6 +87,7 @@ class UpdateRollBackToEmbedded extends EasCommand_1.default {
84
87
  projectId,
85
88
  vcsClient,
86
89
  env: undefined,
90
+ manifestHostOverride: easJsonUpdateConfig.manifestHostOverride ?? null,
87
91
  });
88
92
  // check that the expo-updates package version supports roll back to embedded
89
93
  await (0, projectUtils_1.enforceRollBackToEmbeddedUpdateSupportAsync)(projectDir);
@@ -1254,6 +1254,7 @@ export type App = Project & {
1254
1254
  workerDeploymentsCrashes?: Maybe<WorkerDeploymentCrashes>;
1255
1255
  workerDeploymentsRequest: WorkerDeploymentRequestEdge;
1256
1256
  workerDeploymentsRequests?: Maybe<WorkerDeploymentRequests>;
1257
+ workflowRunGitBranchesPaginated: AppWorkflowRunGitBranchesConnection;
1257
1258
  workflowRunsPaginated: AppWorkflowRunsConnection;
1258
1259
  workflows: Array<Workflow>;
1259
1260
  };
@@ -1467,9 +1468,18 @@ export type AppWorkerDeploymentsRequestsArgs = {
1467
1468
  timespan: DatasetTimespan;
1468
1469
  };
1469
1470
  /** Represents an Exponent App (or Experience in legacy terms) */
1471
+ export type AppWorkflowRunGitBranchesPaginatedArgs = {
1472
+ after?: InputMaybe<Scalars['String']['input']>;
1473
+ before?: InputMaybe<Scalars['String']['input']>;
1474
+ filter?: InputMaybe<WorkflowRunGitBranchFilterInput>;
1475
+ first?: InputMaybe<Scalars['Int']['input']>;
1476
+ last?: InputMaybe<Scalars['Int']['input']>;
1477
+ };
1478
+ /** Represents an Exponent App (or Experience in legacy terms) */
1470
1479
  export type AppWorkflowRunsPaginatedArgs = {
1471
1480
  after?: InputMaybe<Scalars['String']['input']>;
1472
1481
  before?: InputMaybe<Scalars['String']['input']>;
1482
+ filter?: InputMaybe<WorkflowRunFilterInput>;
1473
1483
  first?: InputMaybe<Scalars['Int']['input']>;
1474
1484
  last?: InputMaybe<Scalars['Int']['input']>;
1475
1485
  };
@@ -1876,6 +1886,21 @@ export type AppWorkflowRunEdge = {
1876
1886
  cursor: Scalars['String']['output'];
1877
1887
  node: WorkflowRun;
1878
1888
  };
1889
+ export type AppWorkflowRunGitBranchEdge = {
1890
+ __typename?: 'AppWorkflowRunGitBranchEdge';
1891
+ cursor: Scalars['String']['output'];
1892
+ node: AppWorkflowRunGitBranchNode;
1893
+ };
1894
+ export type AppWorkflowRunGitBranchNode = {
1895
+ __typename?: 'AppWorkflowRunGitBranchNode';
1896
+ lastRunAt: Scalars['DateTime']['output'];
1897
+ name: Scalars['String']['output'];
1898
+ };
1899
+ export type AppWorkflowRunGitBranchesConnection = {
1900
+ __typename?: 'AppWorkflowRunGitBranchesConnection';
1901
+ edges: Array<AppWorkflowRunGitBranchEdge>;
1902
+ pageInfo: PageInfo;
1903
+ };
1879
1904
  export type AppWorkflowRunsConnection = {
1880
1905
  __typename?: 'AppWorkflowRunsConnection';
1881
1906
  edges: Array<AppWorkflowRunEdge>;
@@ -4945,6 +4970,7 @@ export type PublicArtifacts = {
4945
4970
  buildUrl?: Maybe<Scalars['String']['output']>;
4946
4971
  };
4947
4972
  export type PublishUpdateGroupInput = {
4973
+ assetHostOverride?: InputMaybe<Scalars['String']['input']>;
4948
4974
  assetMapGroup?: InputMaybe<AssetMapGroup>;
4949
4975
  awaitingCodeSigningInfo?: InputMaybe<Scalars['Boolean']['input']>;
4950
4976
  branchId: Scalars['String']['input'];
@@ -4953,6 +4979,7 @@ export type PublishUpdateGroupInput = {
4953
4979
  fingerprintInfoGroup?: InputMaybe<FingerprintInfoGroup>;
4954
4980
  gitCommitHash?: InputMaybe<Scalars['String']['input']>;
4955
4981
  isGitWorkingTreeDirty?: InputMaybe<Scalars['Boolean']['input']>;
4982
+ manifestHostOverride?: InputMaybe<Scalars['String']['input']>;
4956
4983
  message?: InputMaybe<Scalars['String']['input']>;
4957
4984
  rollBackToEmbeddedInfoGroup?: InputMaybe<UpdateRollBackToEmbeddedGroup>;
4958
4985
  rolloutInfoGroup?: InputMaybe<UpdateRolloutInfoGroup>;
@@ -5922,6 +5949,7 @@ export type Update = ActivityTimelineProjectActivity & {
5922
5949
  activityTimestamp: Scalars['DateTime']['output'];
5923
5950
  actor?: Maybe<Actor>;
5924
5951
  app: App;
5952
+ assetHostOverride?: Maybe<Scalars['String']['output']>;
5925
5953
  assetMapUrl?: Maybe<Scalars['String']['output']>;
5926
5954
  awaitingCodeSigningInfo: Scalars['Boolean']['output'];
5927
5955
  branch: UpdateBranch;
@@ -5941,6 +5969,7 @@ export type Update = ActivityTimelineProjectActivity & {
5941
5969
  isRollBackToEmbedded: Scalars['Boolean']['output'];
5942
5970
  jobRun?: Maybe<JobRun>;
5943
5971
  manifestFragment: Scalars['String']['output'];
5972
+ manifestHostOverride?: Maybe<Scalars['String']['output']>;
5944
5973
  manifestPermalink: Scalars['String']['output'];
5945
5974
  message?: Maybe<Scalars['String']['output']>;
5946
5975
  platform: Scalars['String']['output'];
@@ -7052,6 +7081,7 @@ export type WorkerDeploymentRequestNode = {
7052
7081
  requestId: Scalars['WorkerDeploymentRequestID']['output'];
7053
7082
  requestTimestamp: Scalars['DateTime']['output'];
7054
7083
  responseType: ResponseType;
7084
+ routerPath?: Maybe<Scalars['String']['output']>;
7055
7085
  scriptName: Scalars['String']['output'];
7056
7086
  search?: Maybe<Scalars['String']['output']>;
7057
7087
  status: Scalars['Int']['output'];
@@ -7396,7 +7426,6 @@ export type WorkflowRun = ActivityTimelineProjectActivity & {
7396
7426
  gitCommitMessage?: Maybe<Scalars['String']['output']>;
7397
7427
  githubRepository?: Maybe<GitHubRepository>;
7398
7428
  id: Scalars['ID']['output'];
7399
- initiatingUser?: Maybe<User>;
7400
7429
  jobs: Array<WorkflowJob>;
7401
7430
  name: Scalars['String']['output'];
7402
7431
  pullRequestNumber?: Maybe<Scalars['Int']['output']>;
@@ -7422,6 +7451,12 @@ export type WorkflowRunError = {
7422
7451
  message: Scalars['String']['output'];
7423
7452
  title?: Maybe<Scalars['String']['output']>;
7424
7453
  };
7454
+ export type WorkflowRunFilterInput = {
7455
+ requestedGitRef?: InputMaybe<Scalars['String']['input']>;
7456
+ };
7457
+ export type WorkflowRunGitBranchFilterInput = {
7458
+ searchTerm?: InputMaybe<Scalars['String']['input']>;
7459
+ };
7425
7460
  export type WorkflowRunInput = {
7426
7461
  projectSource: WorkflowProjectSourceInput;
7427
7462
  };
@@ -12041,6 +12076,8 @@ export type UpdatePublishMutation = {
12041
12076
  manifestPermalink: string;
12042
12077
  gitCommitHash?: string | null;
12043
12078
  rolloutPercentage?: number | null;
12079
+ manifestHostOverride?: string | null;
12080
+ assetHostOverride?: string | null;
12044
12081
  actor?: {
12045
12082
  __typename: 'Robot';
12046
12083
  firstName?: string | null;
@@ -12127,6 +12164,8 @@ export type SetRolloutPercentageMutation = {
12127
12164
  manifestPermalink: string;
12128
12165
  gitCommitHash?: string | null;
12129
12166
  rolloutPercentage?: number | null;
12167
+ manifestHostOverride?: string | null;
12168
+ assetHostOverride?: string | null;
12130
12169
  actor?: {
12131
12170
  __typename: 'Robot';
12132
12171
  firstName?: string | null;
@@ -12622,6 +12661,8 @@ export type BranchesByAppQuery = {
12622
12661
  manifestPermalink: string;
12623
12662
  gitCommitHash?: string | null;
12624
12663
  rolloutPercentage?: number | null;
12664
+ manifestHostOverride?: string | null;
12665
+ assetHostOverride?: string | null;
12625
12666
  actor?: {
12626
12667
  __typename: 'Robot';
12627
12668
  firstName?: string | null;
@@ -12736,6 +12777,8 @@ export type ViewBranchesOnUpdateChannelQuery = {
12736
12777
  manifestPermalink: string;
12737
12778
  gitCommitHash?: string | null;
12738
12779
  rolloutPercentage?: number | null;
12780
+ manifestHostOverride?: string | null;
12781
+ assetHostOverride?: string | null;
12739
12782
  actor?: {
12740
12783
  __typename: 'Robot';
12741
12784
  firstName?: string | null;
@@ -13241,6 +13284,8 @@ export type ViewUpdateChannelOnAppQuery = {
13241
13284
  manifestPermalink: string;
13242
13285
  gitCommitHash?: string | null;
13243
13286
  rolloutPercentage?: number | null;
13287
+ manifestHostOverride?: string | null;
13288
+ assetHostOverride?: string | null;
13244
13289
  actor?: {
13245
13290
  __typename: 'Robot';
13246
13291
  firstName?: string | null;
@@ -13324,6 +13369,8 @@ export type ViewUpdateChannelsOnAppQuery = {
13324
13369
  manifestPermalink: string;
13325
13370
  gitCommitHash?: string | null;
13326
13371
  rolloutPercentage?: number | null;
13372
+ manifestHostOverride?: string | null;
13373
+ assetHostOverride?: string | null;
13327
13374
  actor?: {
13328
13375
  __typename: 'Robot';
13329
13376
  firstName?: string | null;
@@ -13844,6 +13891,8 @@ export type ViewUpdatesByGroupQuery = {
13844
13891
  manifestPermalink: string;
13845
13892
  gitCommitHash?: string | null;
13846
13893
  rolloutPercentage?: number | null;
13894
+ manifestHostOverride?: string | null;
13895
+ assetHostOverride?: string | null;
13847
13896
  actor?: {
13848
13897
  __typename: 'Robot';
13849
13898
  firstName?: string | null;
@@ -13916,6 +13965,8 @@ export type ViewUpdateGroupsOnBranchQuery = {
13916
13965
  manifestPermalink: string;
13917
13966
  gitCommitHash?: string | null;
13918
13967
  rolloutPercentage?: number | null;
13968
+ manifestHostOverride?: string | null;
13969
+ assetHostOverride?: string | null;
13919
13970
  actor?: {
13920
13971
  __typename: 'Robot';
13921
13972
  firstName?: string | null;
@@ -13987,6 +14038,8 @@ export type ViewUpdateGroupsOnAppQuery = {
13987
14038
  manifestPermalink: string;
13988
14039
  gitCommitHash?: string | null;
13989
14040
  rolloutPercentage?: number | null;
14041
+ manifestHostOverride?: string | null;
14042
+ assetHostOverride?: string | null;
13990
14043
  actor?: {
13991
14044
  __typename: 'Robot';
13992
14045
  firstName?: string | null;
@@ -14051,6 +14104,8 @@ export type UpdateByIdQuery = {
14051
14104
  manifestPermalink: string;
14052
14105
  gitCommitHash?: string | null;
14053
14106
  rolloutPercentage?: number | null;
14107
+ manifestHostOverride?: string | null;
14108
+ assetHostOverride?: string | null;
14054
14109
  actor?: {
14055
14110
  __typename: 'Robot';
14056
14111
  firstName?: string | null;
@@ -14865,6 +14920,8 @@ export type UpdateFragment = {
14865
14920
  manifestPermalink: string;
14866
14921
  gitCommitHash?: string | null;
14867
14922
  rolloutPercentage?: number | null;
14923
+ manifestHostOverride?: string | null;
14924
+ assetHostOverride?: string | null;
14868
14925
  actor?: {
14869
14926
  __typename: 'Robot';
14870
14927
  firstName?: string | null;
@@ -14923,6 +14980,8 @@ export type UpdateBranchFragment = {
14923
14980
  manifestPermalink: string;
14924
14981
  gitCommitHash?: string | null;
14925
14982
  rolloutPercentage?: number | null;
14983
+ manifestHostOverride?: string | null;
14984
+ assetHostOverride?: string | null;
14926
14985
  actor?: {
14927
14986
  __typename: 'Robot';
14928
14987
  firstName?: string | null;
@@ -48,5 +48,7 @@ exports.UpdateFragmentNode = (0, graphql_tag_1.default) `
48
48
  isDebugFingerprint
49
49
  }
50
50
  }
51
+ manifestHostOverride
52
+ assetHostOverride
51
53
  }
52
54
  `;
@@ -2,7 +2,7 @@ import { ExpoConfig } from '@expo/config';
2
2
  import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
3
3
  import { AccountFragment } from '../graphql/generated';
4
4
  import { Actor } from '../user/User';
5
- export declare function getUsername(exp: ExpoConfig, user: Actor): string | undefined;
5
+ export declare function getUsernameForBuildMetadataAndBuildJob(user: Actor): string | undefined;
6
6
  /**
7
7
  * Return a useful name describing the project config.
8
8
  * - dynamic: app.config.js
@@ -16,7 +16,7 @@ export declare function isExpoNotificationsInstalled(projectDir: string): boolea
16
16
  export declare function isExpoInstalled(projectDir: string): boolean;
17
17
  export declare function isExpoUpdatesInstalledAsDevDependency(projectDir: string): boolean;
18
18
  export declare function isExpoUpdatesInstalledOrAvailable(projectDir: string, sdkVersion?: string): boolean;
19
- export declare function isUsingEASUpdate(exp: ExpoConfig, projectId: string): boolean;
19
+ export declare function isUsingEASUpdate(exp: ExpoConfig, projectId: string, manifestHostOverride: string | null): boolean;
20
20
  export declare function getExpoUpdatesPackageVersionIfInstalledAsync(projectDir: string): Promise<string | null>;
21
21
  export declare function validateAppVersionRuntimePolicySupportAsync(projectDir: string, exp: ExpoConfig): Promise<void>;
22
22
  export declare function enforceRollBackToEmbeddedUpdateSupportAsync(projectDir: string): Promise<void>;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getDisplayNameForProjectIdAsync = exports.getOwnerAccountForProjectIdAsync = exports.installExpoUpdatesAsync = exports.isModernExpoUpdatesCLIWithRuntimeVersionCommandSupportedAsync = exports.enforceRollBackToEmbeddedUpdateSupportAsync = exports.validateAppVersionRuntimePolicySupportAsync = exports.getExpoUpdatesPackageVersionIfInstalledAsync = exports.isUsingEASUpdate = exports.isExpoUpdatesInstalledOrAvailable = exports.isExpoUpdatesInstalledAsDevDependency = exports.isExpoInstalled = exports.isExpoNotificationsInstalled = exports.isExpoUpdatesInstalled = exports.getProjectConfigDescription = exports.getUsername = void 0;
3
+ exports.getDisplayNameForProjectIdAsync = exports.getOwnerAccountForProjectIdAsync = exports.installExpoUpdatesAsync = exports.isModernExpoUpdatesCLIWithRuntimeVersionCommandSupportedAsync = exports.enforceRollBackToEmbeddedUpdateSupportAsync = exports.validateAppVersionRuntimePolicySupportAsync = exports.getExpoUpdatesPackageVersionIfInstalledAsync = exports.isUsingEASUpdate = exports.isExpoUpdatesInstalledOrAvailable = exports.isExpoUpdatesInstalledAsDevDependency = exports.isExpoInstalled = exports.isExpoNotificationsInstalled = exports.isExpoUpdatesInstalled = exports.getProjectConfigDescription = exports.getUsernameForBuildMetadataAndBuildJob = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const config_1 = require("@expo/config");
6
6
  const chalk_1 = tslib_1.__importDefault(require("chalk"));
@@ -12,22 +12,18 @@ const api_1 = require("../api");
12
12
  const AppQuery_1 = require("../graphql/queries/AppQuery");
13
13
  const log_1 = tslib_1.__importStar(require("../log"));
14
14
  const expoCli_1 = require("../utils/expoCli");
15
- function getUsername(exp, user) {
15
+ function getUsernameForBuildMetadataAndBuildJob(user) {
16
16
  switch (user.__typename) {
17
17
  case 'User':
18
18
  return user.username;
19
19
  case 'SSOUser':
20
20
  return user.username;
21
21
  case 'Robot':
22
- // owner field is necessary to run `expo prebuild`
23
- if (!exp.owner) {
24
- throw new Error('The "owner" manifest property is required when using robot users. See: https://docs.expo.dev/versions/latest/config/app/#owner');
25
- }
26
22
  // robot users don't have usernames
27
23
  return undefined;
28
24
  }
29
25
  }
30
- exports.getUsername = getUsername;
26
+ exports.getUsernameForBuildMetadataAndBuildJob = getUsernameForBuildMetadataAndBuildJob;
31
27
  /**
32
28
  * Return a useful name describing the project config.
33
29
  * - dynamic: app.config.js
@@ -78,8 +74,8 @@ function isExpoUpdatesInstalledOrAvailable(projectDir, sdkVersion) {
78
74
  return isExpoUpdatesInstalled(projectDir);
79
75
  }
80
76
  exports.isExpoUpdatesInstalledOrAvailable = isExpoUpdatesInstalledOrAvailable;
81
- function isUsingEASUpdate(exp, projectId) {
82
- return exp.updates?.url === (0, api_1.getEASUpdateURL)(projectId);
77
+ function isUsingEASUpdate(exp, projectId, manifestHostOverride) {
78
+ return exp.updates?.url === (0, api_1.getEASUpdateURL)(projectId, manifestHostOverride);
83
79
  }
84
80
  exports.isUsingEASUpdate = isUsingEASUpdate;
85
81
  async function getExpoUpdatesPackageVersionIfInstalledAsync(projectDir) {
@@ -212,4 +212,11 @@ export declare function getRuntimeToUpdateRolloutInfoGroupMappingAsync(graphqlCl
212
212
  platforms: UpdatePublishPlatform[];
213
213
  })[];
214
214
  }): Promise<Map<string, UpdateRolloutInfoGroup>>;
215
+ export declare function getUpdateRolloutInfoGroupAsync(graphqlClient: ExpoGraphqlClient, { appId, branchName, rolloutPercentage, runtimeVersion, platforms, }: {
216
+ appId: string;
217
+ branchName: string;
218
+ rolloutPercentage: number;
219
+ runtimeVersion: string;
220
+ platforms: UpdatePublishPlatform[];
221
+ }): Promise<UpdateRolloutInfoGroup>;
215
222
  export {};
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getRuntimeToUpdateRolloutInfoGroupMappingAsync = exports.updatePublishPlatformToAppPlatform = exports.platformDisplayNames = exports.findCompatibleBuildsAsync = exports.maybeCalculateFingerprintForRuntimeVersionInfoObjectsWithoutExpoUpdatesAsync = exports.getRuntimeToPlatformsAndFingerprintInfoMappingFromRuntimeVersionInfoObjects = exports.getRuntimeVersionInfoObjectsAsync = exports.defaultPublishPlatforms = exports.getUpdateMessageForCommandAsync = exports.getBranchNameForCommandAsync = exports.isUploadedAssetCountAboveWarningThreshold = exports.uploadAssetsAsync = exports.filterOutAssetsThatAlreadyExistAsync = exports.collectAssetsAsync = exports.getOriginalPathFromAssetMap = exports.getAssetHashFromPath = exports.filterCollectedAssetsByRequestedPlatforms = exports.generateEasMetadataAsync = exports.loadMetadata = exports.resolveInputDirectoryAsync = exports.buildBundlesAsync = exports.buildUnsortedUpdateInfoGroupAsync = exports.convertAssetToUpdateInfoGroupFormatAsync = exports.getStorageKeyForAssetAsync = exports.getStorageKey = exports.getBase64URLEncoding = exports.guessContentTypeFromExtension = exports.MetadataJoi = void 0;
3
+ exports.getUpdateRolloutInfoGroupAsync = exports.getRuntimeToUpdateRolloutInfoGroupMappingAsync = exports.updatePublishPlatformToAppPlatform = exports.platformDisplayNames = exports.findCompatibleBuildsAsync = exports.maybeCalculateFingerprintForRuntimeVersionInfoObjectsWithoutExpoUpdatesAsync = exports.getRuntimeToPlatformsAndFingerprintInfoMappingFromRuntimeVersionInfoObjects = exports.getRuntimeVersionInfoObjectsAsync = exports.defaultPublishPlatforms = exports.getUpdateMessageForCommandAsync = exports.getBranchNameForCommandAsync = exports.isUploadedAssetCountAboveWarningThreshold = exports.uploadAssetsAsync = exports.filterOutAssetsThatAlreadyExistAsync = exports.collectAssetsAsync = exports.getOriginalPathFromAssetMap = exports.getAssetHashFromPath = exports.filterCollectedAssetsByRequestedPlatforms = exports.generateEasMetadataAsync = exports.loadMetadata = exports.resolveInputDirectoryAsync = exports.buildBundlesAsync = exports.buildUnsortedUpdateInfoGroupAsync = exports.convertAssetToUpdateInfoGroupFormatAsync = exports.getStorageKeyForAssetAsync = exports.getStorageKey = exports.getBase64URLEncoding = exports.guessContentTypeFromExtension = exports.MetadataJoi = void 0;
4
4
  const tslib_1 = require("tslib");
5
5
  const config_plugins_1 = require("@expo/config-plugins");
6
6
  const eas_build_job_1 = require("@expo/eas-build-job");
@@ -633,18 +633,28 @@ exports.updatePublishPlatformToAppPlatform = {
633
633
  async function getRuntimeToUpdateRolloutInfoGroupMappingAsync(graphqlClient, { appId, branchName, rolloutPercentage, runtimeToPlatformsAndFingerprintInfoMapping, }) {
634
634
  const runtimeToPlatformsMap = new Map(runtimeToPlatformsAndFingerprintInfoMapping.map(r => [r.runtimeVersion, r.platforms]));
635
635
  return await (0, mapMapAsync_1.default)(runtimeToPlatformsMap, async (platforms, runtimeVersion) => {
636
- return Object.fromEntries(await Promise.all(platforms.map(async (platform) => {
637
- const updateIdForPlatform = await BranchQuery_1.BranchQuery.getLatestUpdateIdOnBranchAsync(graphqlClient, {
638
- appId,
639
- branchName,
640
- runtimeVersion,
641
- platform: exports.updatePublishPlatformToAppPlatform[platform],
642
- });
643
- if (!updateIdForPlatform) {
644
- throw new Error(`No updates on branch ${branchName} for platform ${platform} and runtimeVersion ${runtimeVersion} to roll out from.`);
645
- }
646
- return [platform, { rolloutPercentage, rolloutControlUpdateId: updateIdForPlatform }];
647
- })));
636
+ return await getUpdateRolloutInfoGroupAsync(graphqlClient, {
637
+ appId,
638
+ branchName,
639
+ rolloutPercentage,
640
+ runtimeVersion,
641
+ platforms,
642
+ });
648
643
  });
649
644
  }
650
645
  exports.getRuntimeToUpdateRolloutInfoGroupMappingAsync = getRuntimeToUpdateRolloutInfoGroupMappingAsync;
646
+ async function getUpdateRolloutInfoGroupAsync(graphqlClient, { appId, branchName, rolloutPercentage, runtimeVersion, platforms, }) {
647
+ return Object.fromEntries(await Promise.all(platforms.map(async (platform) => {
648
+ const updateIdForPlatform = await BranchQuery_1.BranchQuery.getLatestUpdateIdOnBranchAsync(graphqlClient, {
649
+ appId,
650
+ branchName,
651
+ runtimeVersion,
652
+ platform: exports.updatePublishPlatformToAppPlatform[platform],
653
+ });
654
+ if (!updateIdForPlatform) {
655
+ throw new Error(`No updates on branch ${branchName} for platform ${platform} and runtimeVersion ${runtimeVersion} to roll out from.`);
656
+ }
657
+ return [platform, { rolloutPercentage, rolloutControlUpdateId: updateIdForPlatform }];
658
+ })));
659
+ }
660
+ exports.getUpdateRolloutInfoGroupAsync = getUpdateRolloutInfoGroupAsync;