eas-cli 16.4.1 → 16.6.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/README.md +86 -79
- package/build/commands/upload.js +78 -3
- package/build/commands/workflow/run.d.ts +2 -0
- package/build/commands/workflow/run.js +96 -6
- package/build/graphql/generated.d.ts +106 -15
- package/build/graphql/generated.js +1 -0
- package/build/graphql/queries/WorkflowRunQuery.d.ts +10 -0
- package/build/graphql/queries/WorkflowRunQuery.js +62 -0
- package/build/utils/plist.d.ts +2 -0
- package/build/utils/plist.js +24 -1
- package/oclif.manifest.json +15 -2
- package/package.json +3 -2
package/build/commands/upload.js
CHANGED
|
@@ -24,6 +24,7 @@ const uploads_1 = require("../uploads");
|
|
|
24
24
|
const date_1 = require("../utils/date");
|
|
25
25
|
const json_1 = require("../utils/json");
|
|
26
26
|
const paths_1 = require("../utils/paths");
|
|
27
|
+
const plist_1 = require("../utils/plist");
|
|
27
28
|
const progress_1 = require("../utils/progress");
|
|
28
29
|
class BuildUpload extends EasCommand_1.default {
|
|
29
30
|
static description = 'upload a local build and generate a sharable link';
|
|
@@ -60,7 +61,7 @@ class BuildUpload extends EasCommand_1.default {
|
|
|
60
61
|
inputBuildPath: buildPath,
|
|
61
62
|
nonInteractive,
|
|
62
63
|
});
|
|
63
|
-
const { fingerprintHash: buildFingerprintHash, developmentClient, simulator, } = await extractAppMetadataAsync(localBuildPath, platform);
|
|
64
|
+
const { fingerprintHash: buildFingerprintHash, developmentClient, simulator, ...otherMetadata } = await extractAppMetadataAsync(localBuildPath, platform);
|
|
64
65
|
let fingerprint = manualFingerprintHash ?? buildFingerprintHash;
|
|
65
66
|
if (fingerprint) {
|
|
66
67
|
if (manualFingerprintHash &&
|
|
@@ -86,7 +87,12 @@ class BuildUpload extends EasCommand_1.default {
|
|
|
86
87
|
log_1.default.log(`Fingerprint hash: ${fingerprint ?? 'Unknown'}`);
|
|
87
88
|
log_1.default.log('Uploading your app archive to EAS');
|
|
88
89
|
const bucketKey = await uploadAppArchiveAsync(graphqlClient, localBuildPath);
|
|
89
|
-
const build = await LocalBuildMutation_1.LocalBuildMutation.createLocalBuildAsync(graphqlClient, projectId, { platform: (0, AppPlatform_1.toAppPlatform)(platform), simulator }, { type: generated_1.LocalBuildArchiveSourceType.Gcs, bucketKey }, {
|
|
90
|
+
const build = await LocalBuildMutation_1.LocalBuildMutation.createLocalBuildAsync(graphqlClient, projectId, { platform: (0, AppPlatform_1.toAppPlatform)(platform), simulator }, { type: generated_1.LocalBuildArchiveSourceType.Gcs, bucketKey }, {
|
|
91
|
+
distribution: generated_1.DistributionType.Internal,
|
|
92
|
+
fingerprintHash: fingerprint,
|
|
93
|
+
developmentClient,
|
|
94
|
+
...otherMetadata,
|
|
95
|
+
});
|
|
90
96
|
if (jsonFlag) {
|
|
91
97
|
(0, json_1.printJsonOnlyOutput)({ url: (0, url_1.getBuildLogsUrl)(build) });
|
|
92
98
|
return;
|
|
@@ -220,10 +226,23 @@ async function uploadAppArchiveAsync(graphqlClient, originalPath) {
|
|
|
220
226
|
}));
|
|
221
227
|
return bucketKey;
|
|
222
228
|
}
|
|
229
|
+
function getInfoPlistMetadata(infoPlist) {
|
|
230
|
+
const appName = infoPlist?.CFBundleDisplayName ?? infoPlist?.CFBundleName;
|
|
231
|
+
const appIdentifier = infoPlist?.CFBundleIdentifier;
|
|
232
|
+
const simulator = infoPlist?.DTPlatformName?.includes('simulator');
|
|
233
|
+
return {
|
|
234
|
+
appName,
|
|
235
|
+
appIdentifier,
|
|
236
|
+
simulator,
|
|
237
|
+
};
|
|
238
|
+
}
|
|
223
239
|
async function extractAppMetadataAsync(buildPath, platform) {
|
|
224
240
|
let developmentClient = false;
|
|
225
241
|
let fingerprintHash;
|
|
226
|
-
|
|
242
|
+
// By default, we assume the iOS apps are for simulators
|
|
243
|
+
let simulator = platform === eas_build_job_1.Platform.IOS;
|
|
244
|
+
let appName;
|
|
245
|
+
let appIdentifier;
|
|
227
246
|
const basePath = platform === eas_build_job_1.Platform.ANDROID ? 'assets/' : buildPath;
|
|
228
247
|
const fingerprintFilePath = platform === eas_build_job_1.Platform.ANDROID ? 'fingerprint' : 'EXUpdates.bundle/fingerprint';
|
|
229
248
|
const devMenuBundlePath = platform === eas_build_job_1.Platform.ANDROID ? 'EXDevMenuApp.android.js' : 'EXDevMenu.bundle/';
|
|
@@ -245,14 +264,49 @@ async function extractAppMetadataAsync(buildPath, platform) {
|
|
|
245
264
|
}
|
|
246
265
|
else if (buildExtension === '.app') {
|
|
247
266
|
developmentClient = await fs_extra_1.default.exists(path_1.default.join(basePath, devMenuBundlePath));
|
|
267
|
+
if (await fs_extra_1.default.exists(path_1.default.join(basePath, 'Info.plist'))) {
|
|
268
|
+
const infoPlistBuffer = await fs_extra_1.default.readFile(path_1.default.join(basePath, 'Info.plist'));
|
|
269
|
+
const infoPlist = (0, plist_1.parseBinaryPlistBuffer)(infoPlistBuffer);
|
|
270
|
+
({ simulator, appIdentifier, appName } = getInfoPlistMetadata(infoPlist));
|
|
271
|
+
}
|
|
248
272
|
if (await fs_extra_1.default.exists(path_1.default.join(basePath, fingerprintFilePath))) {
|
|
249
273
|
fingerprintHash = await fs_extra_1.default.readFile(path_1.default.join(basePath, fingerprintFilePath), 'utf8');
|
|
250
274
|
}
|
|
251
275
|
}
|
|
276
|
+
else if (buildExtension === '.ipa') {
|
|
277
|
+
const zip = new node_stream_zip_1.default.async({ file: buildPath });
|
|
278
|
+
try {
|
|
279
|
+
const entries = await zip.entries();
|
|
280
|
+
const entriesKeys = Object.keys(entries);
|
|
281
|
+
await Promise.all(entriesKeys.map(async (path) => {
|
|
282
|
+
const infoPlistRegex = /^Payload\/[^/]+\.app\/Info\.plist$/;
|
|
283
|
+
if (infoPlistRegex.test(path)) {
|
|
284
|
+
const infoPlistBuffer = await zip.entryData(entries[path]);
|
|
285
|
+
const infoPlist = (0, plist_1.parseBinaryPlistBuffer)(infoPlistBuffer);
|
|
286
|
+
({ simulator, appIdentifier, appName } = getInfoPlistMetadata(infoPlist));
|
|
287
|
+
return;
|
|
288
|
+
}
|
|
289
|
+
if (path.includes('/EXDevMenu.bundle')) {
|
|
290
|
+
developmentClient = true;
|
|
291
|
+
return;
|
|
292
|
+
}
|
|
293
|
+
if (path.includes('EXUpdates.bundle/fingerprint')) {
|
|
294
|
+
fingerprintHash = (await zip.entryData(entries[path])).toString('utf-8');
|
|
295
|
+
}
|
|
296
|
+
}));
|
|
297
|
+
}
|
|
298
|
+
catch (err) {
|
|
299
|
+
log_1.default.error(`Error reading ${buildExtension}: ${err}`);
|
|
300
|
+
}
|
|
301
|
+
finally {
|
|
302
|
+
await zip.close();
|
|
303
|
+
}
|
|
304
|
+
}
|
|
252
305
|
else {
|
|
253
306
|
// Use tar to list files in the archive
|
|
254
307
|
try {
|
|
255
308
|
let fingerprintHashPromise;
|
|
309
|
+
let infoPlistPromise;
|
|
256
310
|
await tar_1.default.list({
|
|
257
311
|
file: buildPath,
|
|
258
312
|
// eslint-disable-next-line async-protect/async-suffix
|
|
@@ -274,11 +328,30 @@ async function extractAppMetadataAsync(buildPath, platform) {
|
|
|
274
328
|
}
|
|
275
329
|
});
|
|
276
330
|
}
|
|
331
|
+
if (entry.path.endsWith('Info.plist')) {
|
|
332
|
+
infoPlistPromise = new Promise(async (resolve, reject) => {
|
|
333
|
+
try {
|
|
334
|
+
const chunks = [];
|
|
335
|
+
for await (const chunk of entry) {
|
|
336
|
+
chunks.push(chunk);
|
|
337
|
+
}
|
|
338
|
+
const content = Buffer.concat(chunks);
|
|
339
|
+
resolve(content);
|
|
340
|
+
}
|
|
341
|
+
catch (error) {
|
|
342
|
+
reject(error);
|
|
343
|
+
}
|
|
344
|
+
});
|
|
345
|
+
}
|
|
277
346
|
},
|
|
278
347
|
});
|
|
279
348
|
if (fingerprintHashPromise !== undefined) {
|
|
280
349
|
fingerprintHash = await fingerprintHashPromise;
|
|
281
350
|
}
|
|
351
|
+
if (infoPlistPromise !== undefined) {
|
|
352
|
+
const infoPlist = (0, plist_1.parseBinaryPlistBuffer)(await infoPlistPromise);
|
|
353
|
+
({ simulator, appIdentifier, appName } = getInfoPlistMetadata(infoPlist));
|
|
354
|
+
}
|
|
282
355
|
}
|
|
283
356
|
catch (err) {
|
|
284
357
|
log_1.default.error(`Error reading ${buildExtension}: ${err}`);
|
|
@@ -288,5 +361,7 @@ async function extractAppMetadataAsync(buildPath, platform) {
|
|
|
288
361
|
developmentClient,
|
|
289
362
|
fingerprintHash,
|
|
290
363
|
simulator,
|
|
364
|
+
appName,
|
|
365
|
+
appIdentifier,
|
|
291
366
|
};
|
|
292
367
|
}
|
|
@@ -6,6 +6,8 @@ export default class WorkflowRun extends EasCommand {
|
|
|
6
6
|
description: string;
|
|
7
7
|
}[];
|
|
8
8
|
static flags: {
|
|
9
|
+
json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
10
|
+
wait: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
9
11
|
'non-interactive': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
10
12
|
};
|
|
11
13
|
static contextDefinition: {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const core_1 = require("@
|
|
4
|
+
const core_1 = require("@oclif/core");
|
|
5
|
+
const core_2 = require("@urql/core");
|
|
5
6
|
const path = tslib_1.__importStar(require("node:path"));
|
|
6
7
|
const url_1 = require("../../build/utils/url");
|
|
7
8
|
const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
|
|
@@ -9,16 +10,32 @@ const flags_1 = require("../../commandUtils/flags");
|
|
|
9
10
|
const generated_1 = require("../../graphql/generated");
|
|
10
11
|
const WorkflowRevisionMutation_1 = require("../../graphql/mutations/WorkflowRevisionMutation");
|
|
11
12
|
const WorkflowRunMutation_1 = require("../../graphql/mutations/WorkflowRunMutation");
|
|
13
|
+
const WorkflowRunQuery_1 = require("../../graphql/queries/WorkflowRunQuery");
|
|
12
14
|
const log_1 = tslib_1.__importStar(require("../../log"));
|
|
15
|
+
const ora_1 = require("../../ora");
|
|
13
16
|
const projectUtils_1 = require("../../project/projectUtils");
|
|
14
17
|
const uploadAccountScopedFileAsync_1 = require("../../project/uploadAccountScopedFileAsync");
|
|
15
18
|
const uploadAccountScopedProjectSourceAsync_1 = require("../../project/uploadAccountScopedProjectSourceAsync");
|
|
19
|
+
const json_1 = require("../../utils/json");
|
|
20
|
+
const promise_1 = require("../../utils/promise");
|
|
16
21
|
const workflowFile_1 = require("../../utils/workflowFile");
|
|
22
|
+
const EXIT_CODES = {
|
|
23
|
+
WORKFLOW_FAILED: 11,
|
|
24
|
+
WORKFLOW_CANCELED: 12,
|
|
25
|
+
WAIT_ABORTED: 13,
|
|
26
|
+
};
|
|
17
27
|
class WorkflowRun extends EasCommand_1.default {
|
|
18
|
-
static description = '
|
|
28
|
+
static description = 'run an EAS workflow';
|
|
19
29
|
static args = [{ name: 'file', description: 'Path to the workflow file to run' }];
|
|
20
30
|
static flags = {
|
|
21
31
|
...flags_1.EASNonInteractiveFlag,
|
|
32
|
+
wait: core_1.Flags.boolean({
|
|
33
|
+
default: false,
|
|
34
|
+
allowNo: true,
|
|
35
|
+
description: 'Exit codes: 0 = success, 11 = failure, 12 = canceled, 13 = wait aborted.',
|
|
36
|
+
summary: 'Wait for workflow run to complete',
|
|
37
|
+
}),
|
|
38
|
+
...flags_1.EasJsonOnlyFlag,
|
|
22
39
|
};
|
|
23
40
|
static contextDefinition = {
|
|
24
41
|
...this.ContextOptions.DynamicProjectConfig,
|
|
@@ -28,6 +45,9 @@ class WorkflowRun extends EasCommand_1.default {
|
|
|
28
45
|
};
|
|
29
46
|
async runAsync() {
|
|
30
47
|
const { flags, args } = await this.parse(WorkflowRun);
|
|
48
|
+
if (flags.json) {
|
|
49
|
+
(0, json_1.enableJsonOutput)();
|
|
50
|
+
}
|
|
31
51
|
const { getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, vcsClient, projectDir, } = await this.getContextAsync(WorkflowRun, {
|
|
32
52
|
nonInteractive: flags['non-interactive'],
|
|
33
53
|
withServerSideEnvironment: null,
|
|
@@ -54,7 +74,7 @@ class WorkflowRun extends EasCommand_1.default {
|
|
|
54
74
|
});
|
|
55
75
|
}
|
|
56
76
|
catch (error) {
|
|
57
|
-
if (error instanceof
|
|
77
|
+
if (error instanceof core_2.CombinedError) {
|
|
58
78
|
workflowFile_1.WorkflowFile.maybePrintWorkflowFileValidationErrors({
|
|
59
79
|
error,
|
|
60
80
|
accountName: account.name,
|
|
@@ -89,8 +109,9 @@ class WorkflowRun extends EasCommand_1.default {
|
|
|
89
109
|
log_1.default.error('Failed to upload project sources.');
|
|
90
110
|
throw err;
|
|
91
111
|
}
|
|
112
|
+
let workflowRunId;
|
|
92
113
|
try {
|
|
93
|
-
|
|
114
|
+
({ id: workflowRunId } = await WorkflowRunMutation_1.WorkflowRunMutation.createWorkflowRunAsync(graphqlClient, {
|
|
94
115
|
appId: projectId,
|
|
95
116
|
workflowRevisionInput: {
|
|
96
117
|
fileName: path.basename(args.file),
|
|
@@ -104,14 +125,83 @@ class WorkflowRun extends EasCommand_1.default {
|
|
|
104
125
|
packageJsonBucketKey,
|
|
105
126
|
},
|
|
106
127
|
},
|
|
107
|
-
});
|
|
128
|
+
}));
|
|
108
129
|
log_1.default.newLine();
|
|
109
|
-
log_1.default.
|
|
130
|
+
log_1.default.log(`See logs: ${(0, log_1.link)((0, url_1.getWorkflowRunUrl)(account.name, projectName, workflowRunId))}`);
|
|
110
131
|
}
|
|
111
132
|
catch (err) {
|
|
112
133
|
log_1.default.error('Failed to start the workflow with the API.');
|
|
113
134
|
throw err;
|
|
114
135
|
}
|
|
136
|
+
if (!flags.wait) {
|
|
137
|
+
log_1.default.succeed('Workflow run started successfully.');
|
|
138
|
+
if (flags.json) {
|
|
139
|
+
(0, json_1.printJsonOnlyOutput)({
|
|
140
|
+
id: workflowRunId,
|
|
141
|
+
url: (0, url_1.getWorkflowRunUrl)(account.name, projectName, workflowRunId),
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
process.exit(0);
|
|
145
|
+
}
|
|
146
|
+
log_1.default.newLine();
|
|
147
|
+
const { status } = await waitForWorkflowRunToEndAsync(graphqlClient, {
|
|
148
|
+
workflowRunId,
|
|
149
|
+
});
|
|
150
|
+
if (flags.json) {
|
|
151
|
+
const workflowRun = await WorkflowRunQuery_1.WorkflowRunQuery.withJobsByIdAsync(graphqlClient, workflowRunId, {
|
|
152
|
+
useCache: false,
|
|
153
|
+
});
|
|
154
|
+
(0, json_1.printJsonOnlyOutput)({
|
|
155
|
+
...workflowRun,
|
|
156
|
+
url: (0, url_1.getWorkflowRunUrl)(account.name, projectName, workflowRunId),
|
|
157
|
+
});
|
|
158
|
+
}
|
|
159
|
+
if (status === generated_1.WorkflowRunStatus.Failure) {
|
|
160
|
+
process.exit(EXIT_CODES.WORKFLOW_FAILED);
|
|
161
|
+
}
|
|
162
|
+
else if (status === generated_1.WorkflowRunStatus.Canceled) {
|
|
163
|
+
process.exit(EXIT_CODES.WORKFLOW_CANCELED);
|
|
164
|
+
}
|
|
115
165
|
}
|
|
116
166
|
}
|
|
117
167
|
exports.default = WorkflowRun;
|
|
168
|
+
async function waitForWorkflowRunToEndAsync(graphqlClient, { workflowRunId }) {
|
|
169
|
+
log_1.default.log('Waiting for workflow run to complete. You can press Ctrl+C to exit.');
|
|
170
|
+
const spinner = (0, ora_1.ora)('Currently waiting for workflow run to start.').start();
|
|
171
|
+
let failedFetchesCount = 0;
|
|
172
|
+
while (true) {
|
|
173
|
+
try {
|
|
174
|
+
const workflowRun = await WorkflowRunQuery_1.WorkflowRunQuery.byIdAsync(graphqlClient, workflowRunId, {
|
|
175
|
+
useCache: false,
|
|
176
|
+
});
|
|
177
|
+
failedFetchesCount = 0;
|
|
178
|
+
switch (workflowRun.status) {
|
|
179
|
+
case generated_1.WorkflowRunStatus.InProgress:
|
|
180
|
+
spinner.start('Workflow run is in progress.');
|
|
181
|
+
break;
|
|
182
|
+
case generated_1.WorkflowRunStatus.ActionRequired:
|
|
183
|
+
spinner.warn('Workflow run is waiting for action.');
|
|
184
|
+
break;
|
|
185
|
+
case generated_1.WorkflowRunStatus.PendingCancel:
|
|
186
|
+
case generated_1.WorkflowRunStatus.Canceled:
|
|
187
|
+
spinner.warn('Workflow run has been canceled.');
|
|
188
|
+
return workflowRun;
|
|
189
|
+
case generated_1.WorkflowRunStatus.Failure:
|
|
190
|
+
spinner.fail('Workflow run has failed.');
|
|
191
|
+
return workflowRun;
|
|
192
|
+
case generated_1.WorkflowRunStatus.Success:
|
|
193
|
+
spinner.succeed('Workflow run completed successfully.');
|
|
194
|
+
return workflowRun;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
catch {
|
|
198
|
+
spinner.text = '⚠ Failed to fetch the workflow run status. Check your network connection.';
|
|
199
|
+
failedFetchesCount += 1;
|
|
200
|
+
if (failedFetchesCount > 6) {
|
|
201
|
+
spinner.fail('Failed to fetch the workflow run status 6 times in a row. Aborting wait.');
|
|
202
|
+
process.exit(EXIT_CODES.WAIT_ABORTED);
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
await (0, promise_1.sleepAsync)(10 /* seconds */ * 1000 /* milliseconds */);
|
|
206
|
+
}
|
|
207
|
+
}
|
|
@@ -529,6 +529,8 @@ export type AccountMutation = {
|
|
|
529
529
|
changePlan: Account;
|
|
530
530
|
/** Add specified account Permissions for Actor. Actor must already have at least one permission on the account. */
|
|
531
531
|
grantActorPermissions: Account;
|
|
532
|
+
/** Remove profile image for the account. Do nothing if there's no profile image associated. */
|
|
533
|
+
removeProfileImage: Account;
|
|
532
534
|
/** Rename this account and the primary user's username if this account is a personal account */
|
|
533
535
|
rename: Account;
|
|
534
536
|
/** Requests a refund for the specified charge by requesting a manual refund from support */
|
|
@@ -558,6 +560,9 @@ export type AccountMutationGrantActorPermissionsArgs = {
|
|
|
558
560
|
actorID: Scalars['ID']['input'];
|
|
559
561
|
permissions?: InputMaybe<Array<InputMaybe<Permission>>>;
|
|
560
562
|
};
|
|
563
|
+
export type AccountMutationRemoveProfileImageArgs = {
|
|
564
|
+
accountID: Scalars['ID']['input'];
|
|
565
|
+
};
|
|
561
566
|
export type AccountMutationRenameArgs = {
|
|
562
567
|
accountID: Scalars['ID']['input'];
|
|
563
568
|
newName: Scalars['String']['input'];
|
|
@@ -1574,10 +1579,10 @@ export type AppMutation = {
|
|
|
1574
1579
|
__typename?: 'AppMutation';
|
|
1575
1580
|
/** Create an app */
|
|
1576
1581
|
createApp: App;
|
|
1577
|
-
/** Create an app and GitHub repository if user desire to */
|
|
1578
|
-
createAppAndGithubRepository: CreateAppAndGithubRepositoryResponse;
|
|
1579
1582
|
/** @deprecated No longer supported */
|
|
1580
1583
|
grantAccess?: Maybe<App>;
|
|
1584
|
+
/** Remove profile image (icon) for the app. Do nothing if there's no profile image associated. */
|
|
1585
|
+
removeProfileImage: App;
|
|
1581
1586
|
/** Delete an App. Returns the ID of the background job receipt. Use BackgroundJobReceiptQuery to get the status of the job. */
|
|
1582
1587
|
scheduleAppDeletion: BackgroundJobReceipt;
|
|
1583
1588
|
/** Set display info for app */
|
|
@@ -1590,13 +1595,13 @@ export type AppMutation = {
|
|
|
1590
1595
|
export type AppMutationCreateAppArgs = {
|
|
1591
1596
|
appInput: AppInput;
|
|
1592
1597
|
};
|
|
1593
|
-
export type AppMutationCreateAppAndGithubRepositoryArgs = {
|
|
1594
|
-
appInput: AppWithGithubRepositoryInput;
|
|
1595
|
-
};
|
|
1596
1598
|
export type AppMutationGrantAccessArgs = {
|
|
1597
1599
|
accessLevel?: InputMaybe<Scalars['String']['input']>;
|
|
1598
1600
|
toUser: Scalars['ID']['input'];
|
|
1599
1601
|
};
|
|
1602
|
+
export type AppMutationRemoveProfileImageArgs = {
|
|
1603
|
+
appId: Scalars['ID']['input'];
|
|
1604
|
+
};
|
|
1600
1605
|
export type AppMutationScheduleAppDeletionArgs = {
|
|
1601
1606
|
appId: Scalars['ID']['input'];
|
|
1602
1607
|
};
|
|
@@ -2162,6 +2167,15 @@ export type AscApiKeyInput = {
|
|
|
2162
2167
|
keyIdentifier: Scalars['String']['input'];
|
|
2163
2168
|
keyP8: Scalars['String']['input'];
|
|
2164
2169
|
};
|
|
2170
|
+
export type Asset = {
|
|
2171
|
+
__typename?: 'Asset';
|
|
2172
|
+
contentType: Scalars['String']['output'];
|
|
2173
|
+
fileSHA256: Scalars['String']['output'];
|
|
2174
|
+
fileSize: Scalars['Int']['output'];
|
|
2175
|
+
finalFileSize?: Maybe<Scalars['Int']['output']>;
|
|
2176
|
+
id: Scalars['ID']['output'];
|
|
2177
|
+
storageKey: Scalars['String']['output'];
|
|
2178
|
+
};
|
|
2165
2179
|
export type AssetMapGroup = {
|
|
2166
2180
|
android?: InputMaybe<AssetMapSourceInput>;
|
|
2167
2181
|
ios?: InputMaybe<AssetMapSourceInput>;
|
|
@@ -2197,12 +2211,29 @@ export type AssetMutationGetSignedAssetUploadSpecificationsArgs = {
|
|
|
2197
2211
|
/** Check to see if assets with given storageKeys exist */
|
|
2198
2212
|
export type AssetQuery = {
|
|
2199
2213
|
__typename?: 'AssetQuery';
|
|
2214
|
+
byStorageKeys: Array<Asset>;
|
|
2200
2215
|
metadata: Array<AssetMetadataResult>;
|
|
2216
|
+
signedUrls: Array<AssetSignedUrlResult>;
|
|
2217
|
+
};
|
|
2218
|
+
/** Check to see if assets with given storageKeys exist */
|
|
2219
|
+
export type AssetQueryByStorageKeysArgs = {
|
|
2220
|
+
storageKeys: Array<Scalars['String']['input']>;
|
|
2201
2221
|
};
|
|
2202
2222
|
/** Check to see if assets with given storageKeys exist */
|
|
2203
2223
|
export type AssetQueryMetadataArgs = {
|
|
2204
2224
|
storageKeys: Array<Scalars['String']['input']>;
|
|
2205
2225
|
};
|
|
2226
|
+
/** Check to see if assets with given storageKeys exist */
|
|
2227
|
+
export type AssetQuerySignedUrlsArgs = {
|
|
2228
|
+
storageKeys: Array<Scalars['String']['input']>;
|
|
2229
|
+
updateId: Scalars['ID']['input'];
|
|
2230
|
+
};
|
|
2231
|
+
export type AssetSignedUrlResult = {
|
|
2232
|
+
__typename?: 'AssetSignedUrlResult';
|
|
2233
|
+
headers?: Maybe<Scalars['JSON']['output']>;
|
|
2234
|
+
storageKey: Scalars['String']['output'];
|
|
2235
|
+
url: Scalars['String']['output'];
|
|
2236
|
+
};
|
|
2206
2237
|
export type AuditLog = {
|
|
2207
2238
|
__typename?: 'AuditLog';
|
|
2208
2239
|
account?: Maybe<Account>;
|
|
@@ -2270,9 +2301,11 @@ export declare enum AuthProviderIdentifier {
|
|
|
2270
2301
|
OneLogin = "ONE_LOGIN",
|
|
2271
2302
|
StubIdp = "STUB_IDP"
|
|
2272
2303
|
}
|
|
2273
|
-
export type
|
|
2274
|
-
__typename?: '
|
|
2275
|
-
|
|
2304
|
+
export type AverageAssetMetrics = {
|
|
2305
|
+
__typename?: 'AverageAssetMetrics';
|
|
2306
|
+
averageDownloadSizeBytes: Scalars['Int']['output'];
|
|
2307
|
+
count: Scalars['Int']['output'];
|
|
2308
|
+
storageKey: Scalars['String']['output'];
|
|
2276
2309
|
};
|
|
2277
2310
|
export type BackgroundJobReceipt = {
|
|
2278
2311
|
__typename?: 'BackgroundJobReceipt';
|
|
@@ -2921,11 +2954,6 @@ export type CreateAndroidSubmissionInput = {
|
|
|
2921
2954
|
config: AndroidSubmissionConfigInput;
|
|
2922
2955
|
submittedBuildId?: InputMaybe<Scalars['ID']['input']>;
|
|
2923
2956
|
};
|
|
2924
|
-
export type CreateAppAndGithubRepositoryResponse = {
|
|
2925
|
-
__typename?: 'CreateAppAndGithubRepositoryResponse';
|
|
2926
|
-
app: App;
|
|
2927
|
-
cloneUrl?: Maybe<Scalars['String']['output']>;
|
|
2928
|
-
};
|
|
2929
2957
|
export type CreateBuildResult = {
|
|
2930
2958
|
__typename?: 'CreateBuildResult';
|
|
2931
2959
|
build: Build;
|
|
@@ -3014,6 +3042,11 @@ export type CreateSubmissionResult = {
|
|
|
3014
3042
|
/** Created submission */
|
|
3015
3043
|
submission: Submission;
|
|
3016
3044
|
};
|
|
3045
|
+
export type CumulativeAverageMetrics = {
|
|
3046
|
+
__typename?: 'CumulativeAverageMetrics';
|
|
3047
|
+
averageUpdatePayloadBytes: Scalars['Int']['output'];
|
|
3048
|
+
launchAssetCount: Scalars['Int']['output'];
|
|
3049
|
+
};
|
|
3017
3050
|
export type CumulativeMetrics = {
|
|
3018
3051
|
__typename?: 'CumulativeMetrics';
|
|
3019
3052
|
data: UpdatesMetricsData;
|
|
@@ -3383,6 +3416,7 @@ export declare enum EasServiceMetric {
|
|
|
3383
3416
|
AssetsRequests = "ASSETS_REQUESTS",
|
|
3384
3417
|
BandwidthUsage = "BANDWIDTH_USAGE",
|
|
3385
3418
|
Builds = "BUILDS",
|
|
3419
|
+
LocalBuilds = "LOCAL_BUILDS",
|
|
3386
3420
|
ManifestRequests = "MANIFEST_REQUESTS",
|
|
3387
3421
|
RunTime = "RUN_TIME",
|
|
3388
3422
|
UniqueUpdaters = "UNIQUE_UPDATERS",
|
|
@@ -4938,6 +4972,7 @@ export declare enum RequestMethod {
|
|
|
4938
4972
|
export type RequestsFilters = {
|
|
4939
4973
|
cacheStatus?: InputMaybe<Array<ResponseCacheStatus>>;
|
|
4940
4974
|
continent?: InputMaybe<Array<ContinentCode>>;
|
|
4975
|
+
country?: InputMaybe<Array<Scalars['String']['input']>>;
|
|
4941
4976
|
hasCustomDomainOrigin?: InputMaybe<Scalars['Boolean']['input']>;
|
|
4942
4977
|
isAsset?: InputMaybe<Scalars['Boolean']['input']>;
|
|
4943
4978
|
isCrash?: InputMaybe<Scalars['Boolean']['input']>;
|
|
@@ -5310,6 +5345,7 @@ export type RootQueryAppByAppIdArgs = {
|
|
|
5310
5345
|
};
|
|
5311
5346
|
export type RootQueryUpdatesByGroupArgs = {
|
|
5312
5347
|
group: Scalars['ID']['input'];
|
|
5348
|
+
platform?: InputMaybe<Scalars['String']['input']>;
|
|
5313
5349
|
};
|
|
5314
5350
|
export type RootQueryUserByUserIdArgs = {
|
|
5315
5351
|
userId: Scalars['String']['input'];
|
|
@@ -6087,7 +6123,8 @@ export type UpdateInfoGroup = {
|
|
|
6087
6123
|
};
|
|
6088
6124
|
export type UpdateInsights = {
|
|
6089
6125
|
__typename?: 'UpdateInsights';
|
|
6090
|
-
|
|
6126
|
+
averageAssetMetrics: Array<AverageAssetMetrics>;
|
|
6127
|
+
cumulativeAverageMetrics: CumulativeAverageMetrics;
|
|
6091
6128
|
cumulativeMetrics: CumulativeMetrics;
|
|
6092
6129
|
id: Scalars['ID']['output'];
|
|
6093
6130
|
totalUniqueUsers: Scalars['Int']['output'];
|
|
@@ -6580,7 +6617,12 @@ export declare enum UserEntityTypeName {
|
|
|
6580
6617
|
export type UserInvitation = {
|
|
6581
6618
|
__typename?: 'UserInvitation';
|
|
6582
6619
|
accountName: Scalars['String']['output'];
|
|
6583
|
-
/**
|
|
6620
|
+
/** The profile image URL of the account owner */
|
|
6621
|
+
accountProfileImageUrl: Scalars['String']['output'];
|
|
6622
|
+
/**
|
|
6623
|
+
* If the invite is for a personal team, the profile photo of account owner
|
|
6624
|
+
* @deprecated Use accountProfileImageUrl
|
|
6625
|
+
*/
|
|
6584
6626
|
accountProfilePhoto?: Maybe<Scalars['String']['output']>;
|
|
6585
6627
|
created: Scalars['DateTime']['output'];
|
|
6586
6628
|
/** Email to which this invitation was sent */
|
|
@@ -6643,6 +6685,7 @@ export type UserInvitationMutationResendUserInvitationArgs = {
|
|
|
6643
6685
|
export type UserInvitationPublicData = {
|
|
6644
6686
|
__typename?: 'UserInvitationPublicData';
|
|
6645
6687
|
accountName: Scalars['String']['output'];
|
|
6688
|
+
accountProfileImageUrl: Scalars['String']['output'];
|
|
6646
6689
|
accountProfilePhoto?: Maybe<Scalars['String']['output']>;
|
|
6647
6690
|
created: Scalars['DateTime']['output'];
|
|
6648
6691
|
email: Scalars['String']['output'];
|
|
@@ -6841,6 +6884,8 @@ export type WorkerDeployment = ActivityTimelineProjectActivity & {
|
|
|
6841
6884
|
initiatingActor?: Maybe<Actor>;
|
|
6842
6885
|
logs?: Maybe<WorkerDeploymentLogs>;
|
|
6843
6886
|
requests?: Maybe<WorkerDeploymentRequests>;
|
|
6887
|
+
signedAssetsURL: Scalars['String']['output'];
|
|
6888
|
+
signedDeploymentURL: Scalars['String']['output'];
|
|
6844
6889
|
subdomain: Scalars['String']['output'];
|
|
6845
6890
|
url: Scalars['String']['output'];
|
|
6846
6891
|
};
|
|
@@ -14277,6 +14322,52 @@ export type WebhookByIdQuery = {
|
|
|
14277
14322
|
};
|
|
14278
14323
|
};
|
|
14279
14324
|
};
|
|
14325
|
+
export type WorkflowRunByIdQueryVariables = Exact<{
|
|
14326
|
+
workflowRunId: Scalars['ID']['input'];
|
|
14327
|
+
}>;
|
|
14328
|
+
export type WorkflowRunByIdQuery = {
|
|
14329
|
+
__typename?: 'RootQuery';
|
|
14330
|
+
workflowRuns: {
|
|
14331
|
+
__typename?: 'WorkflowRunQuery';
|
|
14332
|
+
byId: {
|
|
14333
|
+
__typename?: 'WorkflowRun';
|
|
14334
|
+
id: string;
|
|
14335
|
+
status: WorkflowRunStatus;
|
|
14336
|
+
};
|
|
14337
|
+
};
|
|
14338
|
+
};
|
|
14339
|
+
export type WorkflowRunByIdWithJobsQueryVariables = Exact<{
|
|
14340
|
+
workflowRunId: Scalars['ID']['input'];
|
|
14341
|
+
}>;
|
|
14342
|
+
export type WorkflowRunByIdWithJobsQuery = {
|
|
14343
|
+
__typename?: 'RootQuery';
|
|
14344
|
+
workflowRuns: {
|
|
14345
|
+
__typename?: 'WorkflowRunQuery';
|
|
14346
|
+
byId: {
|
|
14347
|
+
__typename?: 'WorkflowRun';
|
|
14348
|
+
id: string;
|
|
14349
|
+
name: string;
|
|
14350
|
+
status: WorkflowRunStatus;
|
|
14351
|
+
createdAt: any;
|
|
14352
|
+
workflow: {
|
|
14353
|
+
__typename?: 'Workflow';
|
|
14354
|
+
id: string;
|
|
14355
|
+
name?: string | null;
|
|
14356
|
+
fileName: string;
|
|
14357
|
+
};
|
|
14358
|
+
jobs: Array<{
|
|
14359
|
+
__typename?: 'WorkflowJob';
|
|
14360
|
+
id: string;
|
|
14361
|
+
key: string;
|
|
14362
|
+
name: string;
|
|
14363
|
+
type: WorkflowJobType;
|
|
14364
|
+
status: WorkflowJobStatus;
|
|
14365
|
+
outputs: any;
|
|
14366
|
+
createdAt: any;
|
|
14367
|
+
}>;
|
|
14368
|
+
};
|
|
14369
|
+
};
|
|
14370
|
+
};
|
|
14280
14371
|
export type AccountFragment = {
|
|
14281
14372
|
__typename?: 'Account';
|
|
14282
14373
|
id: string;
|
|
@@ -341,6 +341,7 @@ var EasServiceMetric;
|
|
|
341
341
|
EasServiceMetric["AssetsRequests"] = "ASSETS_REQUESTS";
|
|
342
342
|
EasServiceMetric["BandwidthUsage"] = "BANDWIDTH_USAGE";
|
|
343
343
|
EasServiceMetric["Builds"] = "BUILDS";
|
|
344
|
+
EasServiceMetric["LocalBuilds"] = "LOCAL_BUILDS";
|
|
344
345
|
EasServiceMetric["ManifestRequests"] = "MANIFEST_REQUESTS";
|
|
345
346
|
EasServiceMetric["RunTime"] = "RUN_TIME";
|
|
346
347
|
EasServiceMetric["UniqueUpdaters"] = "UNIQUE_UPDATERS";
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
2
|
+
import { WorkflowRunByIdQuery, WorkflowRunByIdWithJobsQuery } from '../generated';
|
|
3
|
+
export declare const WorkflowRunQuery: {
|
|
4
|
+
byIdAsync(graphqlClient: ExpoGraphqlClient, workflowRunId: string, { useCache }?: {
|
|
5
|
+
useCache?: boolean | undefined;
|
|
6
|
+
}): Promise<WorkflowRunByIdQuery['workflowRuns']['byId']>;
|
|
7
|
+
withJobsByIdAsync(graphqlClient: ExpoGraphqlClient, workflowRunId: string, { useCache }?: {
|
|
8
|
+
useCache?: boolean | undefined;
|
|
9
|
+
}): Promise<WorkflowRunByIdWithJobsQuery['workflowRuns']['byId']>;
|
|
10
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WorkflowRunQuery = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
|
|
6
|
+
const client_1 = require("../client");
|
|
7
|
+
exports.WorkflowRunQuery = {
|
|
8
|
+
async byIdAsync(graphqlClient, workflowRunId, { useCache = true } = {}) {
|
|
9
|
+
const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
|
|
10
|
+
.query((0, graphql_tag_1.default) `
|
|
11
|
+
query WorkflowRunById($workflowRunId: ID!) {
|
|
12
|
+
workflowRuns {
|
|
13
|
+
byId(workflowRunId: $workflowRunId) {
|
|
14
|
+
id
|
|
15
|
+
status
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
`, { workflowRunId }, {
|
|
20
|
+
requestPolicy: useCache ? 'cache-first' : 'network-only',
|
|
21
|
+
additionalTypenames: ['WorkflowRun'],
|
|
22
|
+
})
|
|
23
|
+
.toPromise());
|
|
24
|
+
return data.workflowRuns.byId;
|
|
25
|
+
},
|
|
26
|
+
async withJobsByIdAsync(graphqlClient, workflowRunId, { useCache = true } = {}) {
|
|
27
|
+
const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
|
|
28
|
+
.query((0, graphql_tag_1.default) `
|
|
29
|
+
query WorkflowRunByIdWithJobs($workflowRunId: ID!) {
|
|
30
|
+
workflowRuns {
|
|
31
|
+
byId(workflowRunId: $workflowRunId) {
|
|
32
|
+
id
|
|
33
|
+
name
|
|
34
|
+
status
|
|
35
|
+
createdAt
|
|
36
|
+
|
|
37
|
+
workflow {
|
|
38
|
+
id
|
|
39
|
+
name
|
|
40
|
+
fileName
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
jobs {
|
|
44
|
+
id
|
|
45
|
+
key
|
|
46
|
+
name
|
|
47
|
+
type
|
|
48
|
+
status
|
|
49
|
+
outputs
|
|
50
|
+
createdAt
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
`, { workflowRunId }, {
|
|
56
|
+
requestPolicy: useCache ? 'cache-first' : 'network-only',
|
|
57
|
+
additionalTypenames: ['WorkflowRun'],
|
|
58
|
+
})
|
|
59
|
+
.toPromise());
|
|
60
|
+
return data.workflowRuns.byId;
|
|
61
|
+
},
|
|
62
|
+
};
|
package/build/utils/plist.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
1
2
|
import { IOSConfig } from '@expo/config-plugins';
|
|
2
3
|
export declare function readPlistAsync(plistPath: string): Promise<object | null>;
|
|
3
4
|
export declare function writePlistAsync(plistPath: string, plistObject: IOSConfig.ExpoPlist | IOSConfig.InfoPlist): Promise<void>;
|
|
5
|
+
export declare function parseBinaryPlistBuffer(contents: Buffer): any;
|