eas-cli 21.1.0 → 21.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (53) hide show
  1. package/README.md +243 -115
  2. package/build/commandUtils/context/contextUtils/getProjectIdAsync.js +31 -16
  3. package/build/commands/observe/events.js +5 -4
  4. package/build/commands/observe/metrics-summary.js +2 -1
  5. package/build/commands/observe/metrics.js +3 -2
  6. package/build/commands/observe/routes.js +3 -2
  7. package/build/commands/observe/session.js +8 -2
  8. package/build/commands/project/icon/set.d.ts +15 -0
  9. package/build/commands/project/icon/set.js +93 -0
  10. package/build/commands/project/init.d.ts +3 -0
  11. package/build/commands/project/init.js +34 -7
  12. package/build/commands/simulator/availability.d.ts +14 -0
  13. package/build/commands/simulator/availability.js +51 -0
  14. package/build/commands/testflight/crashes.d.ts +23 -0
  15. package/build/commands/testflight/crashes.js +82 -0
  16. package/build/commands/testflight/feedback.d.ts +23 -0
  17. package/build/commands/testflight/feedback.js +82 -0
  18. package/build/graphql/generated.d.ts +206 -234
  19. package/build/graphql/generated.js +18 -23
  20. package/build/graphql/mutations/UploadSessionMutation.d.ts +5 -1
  21. package/build/graphql/mutations/UploadSessionMutation.js +15 -0
  22. package/build/graphql/queries/AppQuery.d.ts +1 -0
  23. package/build/graphql/queries/AppQuery.js +19 -0
  24. package/build/graphql/queries/DeviceRunSessionAvailabilityQuery.d.ts +7 -0
  25. package/build/graphql/queries/DeviceRunSessionAvailabilityQuery.js +33 -0
  26. package/build/observe/fetchEvents.js +7 -1
  27. package/build/observe/fetchMetrics.js +6 -0
  28. package/build/observe/fetchNavigationRoutes.js +6 -0
  29. package/build/observe/fetchSessions.d.ts +7 -0
  30. package/build/observe/fetchSessions.js +16 -0
  31. package/build/observe/planGating.d.ts +15 -0
  32. package/build/observe/planGating.js +48 -0
  33. package/build/project/accountSelection.d.ts +4 -0
  34. package/build/project/accountSelection.js +56 -0
  35. package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.js +4 -3
  36. package/build/project/projectInitialization.d.ts +13 -3
  37. package/build/project/projectInitialization.js +52 -80
  38. package/build/testflight/app.d.ts +18 -0
  39. package/build/testflight/app.js +124 -0
  40. package/build/testflight/fetch.d.ts +56 -0
  41. package/build/testflight/fetch.js +116 -0
  42. package/build/testflight/format.d.ts +4 -0
  43. package/build/testflight/format.js +104 -0
  44. package/build/testflight/queries.d.ts +16 -0
  45. package/build/testflight/queries.js +123 -0
  46. package/build/testflight/target.d.ts +15 -0
  47. package/build/testflight/target.js +32 -0
  48. package/build/uploads.d.ts +7 -1
  49. package/build/uploads.js +9 -0
  50. package/build/user/User.d.ts +6 -0
  51. package/build/user/User.js +18 -0
  52. package/oclif.manifest.json +2904 -2468
  53. package/package.json +8 -5
@@ -0,0 +1,82 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ const core_1 = require("@oclif/core");
5
+ const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
6
+ const flags_1 = require("../../commandUtils/flags");
7
+ const pagination_1 = require("../../commandUtils/pagination");
8
+ const app_1 = require("../../testflight/app");
9
+ const queries_1 = require("../../testflight/queries");
10
+ const target_1 = require("../../testflight/target");
11
+ const json_1 = require("../../utils/json");
12
+ class TestFlightFeedback extends EasCommand_1.default {
13
+ static description = 'display screenshot feedback submitted by TestFlight testers, including their comments, device information, and screenshot URLs';
14
+ static examples = [
15
+ '$ eas testflight:feedback \t # Show the most recent feedback submissions',
16
+ '$ eas testflight:feedback --limit 50 --offset 20 \t # Page through submissions',
17
+ '$ eas testflight:feedback --json \t # Print a page of feedback, with paging metadata, as JSON',
18
+ '$ eas testflight:feedback AD8JvKbr0BK0Cj9OnM6WO6I \t # Show a single submission by ID',
19
+ '$ eas testflight:feedback ${{ app_store_connect.beta_feedback.url }} --json \t # Look up whatever an EAS workflow trigger reported',
20
+ ];
21
+ static args = {
22
+ id: core_1.Args.string({
23
+ description: 'ID or App Store Connect API URL of a single submission to show. Accepts ${{ app_store_connect.beta_feedback.id }} or ${{ app_store_connect.beta_feedback.url }} from an EAS workflow trigger.',
24
+ required: false,
25
+ }),
26
+ };
27
+ static flags = {
28
+ type: core_1.Flags.option({
29
+ description: 'Kind of feedback the ID refers to. Only needed when passing a bare ID for a crash; a URL already encodes it.',
30
+ options: ['crash', 'screenshot'],
31
+ })(),
32
+ profile: core_1.Flags.string({
33
+ char: 'e',
34
+ description: 'Name of the submit profile from eas.json used to resolve the bundle identifier and App Store Connect API key. Defaults to "production".',
35
+ }),
36
+ ...pagination_1.EasPaginatedQueryFlags,
37
+ limit: (0, pagination_1.getLimitFlagWithCustomValues)({ defaultTo: queries_1.TESTFLIGHT_PAGE_SIZE, limit: 200 }),
38
+ ...flags_1.EasNonInteractiveAndJsonFlags,
39
+ };
40
+ static contextDefinition = {
41
+ ...this.ContextOptions.ProjectConfig,
42
+ ...this.ContextOptions.LoggedIn,
43
+ ...this.ContextOptions.Analytics,
44
+ ...this.ContextOptions.Vcs,
45
+ };
46
+ async runAsync() {
47
+ const { args, flags } = await this.parse(TestFlightFeedback);
48
+ const paginatedQueryOptions = (0, pagination_1.getPaginatedQueryOptions)(flags);
49
+ const { json, nonInteractive } = paginatedQueryOptions;
50
+ if (json) {
51
+ (0, json_1.enableJsonOutput)();
52
+ }
53
+ if (flags.type && !args.id) {
54
+ throw new Error('--type only applies when looking up a single submission by ID or URL.');
55
+ }
56
+ // Resolved before authenticating so a malformed ID or URL fails fast.
57
+ const target = args.id
58
+ ? (0, target_1.resolveBetaFeedbackTarget)({ idOrUrl: args.id, type: flags.type, defaultType: 'screenshot' })
59
+ : null;
60
+ const { loggedIn: { actor, graphqlClient }, privateProjectConfig: { exp, projectId, projectDir }, analytics, vcsClient, } = await this.getContextAsync(TestFlightFeedback, {
61
+ nonInteractive,
62
+ withServerSideEnvironment: null,
63
+ });
64
+ const app = await (0, app_1.resolveTestFlightAppAsync)({
65
+ actor,
66
+ analytics,
67
+ exp,
68
+ graphqlClient,
69
+ nonInteractive,
70
+ profileName: flags.profile,
71
+ projectDir,
72
+ projectId,
73
+ vcsClient,
74
+ });
75
+ if (target) {
76
+ await (0, queries_1.viewAndRenderBetaFeedbackAsync)(app, target, { json });
77
+ return;
78
+ }
79
+ await (0, queries_1.listAndRenderTestFlightFeedbackAsync)(app, paginatedQueryOptions);
80
+ }
81
+ }
82
+ exports.default = TestFlightFeedback;