shipthis 0.1.34 → 0.1.36

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 (105) hide show
  1. package/README.md +223 -80
  2. package/assets/markdown/agreement-update.md.ejs +12 -0
  3. package/assets/markdown/{android-success.md → android-success.md.ejs} +2 -2
  4. package/assets/markdown/{apikey-create.md → apikey-create.md.ejs} +4 -4
  5. package/assets/markdown/{create-google-play-game.md → create-google-play-game.md.ejs} +2 -2
  6. package/assets/markdown/{invite-service-account.md → invite-service-account.md.ejs} +1 -1
  7. package/assets/markdown/{ios-success.md → ios-success.md.ejs} +2 -2
  8. package/assets/markdown/{privacy-notification.md → privacy-notification.md.ejs} +1 -1
  9. package/assets/markdown/service-account-policy-wizard.md.ejs +26 -0
  10. package/assets/markdown/service-account-policy.md.ejs +30 -0
  11. package/assets/markdown/{ship-failure.md → ship-failure.md.ejs} +1 -1
  12. package/assets/markdown/{ship-success.md → ship-success.md.ejs} +2 -2
  13. package/dist/{AppleBundleIdDetails-By-sSGNl.js → AppleBundleIdDetails-pEVOUXTQ.js} +3 -4
  14. package/dist/{Command-VWMnGslo.js → Command-DhAVAdiI.js} +1 -2
  15. package/dist/{CommandGame-BSVPZzNl.js → CommandGame-C-oV-hb4.js} +2 -2
  16. package/dist/{Create-SR1Mq7BY.js → Create-Dg9ZlwEd.js} +1 -3
  17. package/dist/{GameStatus-1ntFyxEx.js → GameStatus-Dm9TqFfW.js} +9 -17
  18. package/dist/{Import-cedOWPDz.js → Import-BFNNkN-I.js} +2 -4
  19. package/dist/{JobLogTail-C_W8UAMg.js → JobLogTail-RTNIiAUk.js} +2 -5
  20. package/dist/{JobProgress-CI385G53.js → JobProgress-dFWcT0CQ.js} +16 -17
  21. package/dist/{JobStatusTable-CdbKtwJE.js → JobStatusTable-BlvMuWF7.js} +2 -4
  22. package/dist/{ProjectCredentialsTable-ZnuIfcDB.js → ProjectCredentialsTable-CMBnYLou.js} +2 -2
  23. package/dist/{UserCredentialsTable-DRkAYgEA.js → UserCredentialsTable-oxE3mDmE.js} +8 -10
  24. package/dist/{baseAppleCommand-CsO-_Yzn.js → baseAppleCommand-cnLvBz95.js} +1 -1
  25. package/dist/{baseGameAndroidCommand-CdjaAbNX.js → baseGameAndroidCommand-DUDYisYm.js} +1 -2
  26. package/dist/commands/apiKey/create.js +15 -16
  27. package/dist/commands/apiKey/list.js +6 -7
  28. package/dist/commands/apiKey/revoke.js +7 -8
  29. package/dist/commands/apple/apiKey/create.js +7 -8
  30. package/dist/commands/apple/apiKey/export.js +6 -7
  31. package/dist/commands/apple/apiKey/import.js +6 -7
  32. package/dist/commands/apple/apiKey/status.js +12 -13
  33. package/dist/commands/apple/certificate/create.js +7 -8
  34. package/dist/commands/apple/certificate/export.js +6 -7
  35. package/dist/commands/apple/certificate/import.js +6 -7
  36. package/dist/commands/apple/certificate/status.js +12 -13
  37. package/dist/commands/apple/login.js +12 -2
  38. package/dist/commands/apple/status.js +4 -5
  39. package/dist/commands/dashboard.js +11 -1
  40. package/dist/commands/game/android/apiKey/connect.js +9 -9
  41. package/dist/commands/game/android/apiKey/create.js +11 -11
  42. package/dist/commands/game/android/apiKey/export.js +7 -8
  43. package/dist/commands/game/android/apiKey/import.js +7 -8
  44. package/dist/commands/game/android/apiKey/invite.js +13 -4
  45. package/dist/commands/game/android/apiKey/policy.js +83 -0
  46. package/dist/commands/game/android/apiKey/status.js +7 -8
  47. package/dist/commands/game/android/keyStore/create.js +8 -9
  48. package/dist/commands/game/android/keyStore/export.js +6 -7
  49. package/dist/commands/game/android/keyStore/import.js +9 -10
  50. package/dist/commands/game/android/keyStore/status.js +6 -7
  51. package/dist/commands/game/android/status.js +12 -1
  52. package/dist/commands/game/build/download.js +4 -5
  53. package/dist/commands/game/build/list.js +5 -6
  54. package/dist/commands/game/create.js +12 -2
  55. package/dist/commands/game/details.js +4 -5
  56. package/dist/commands/game/export.js +12 -1
  57. package/dist/commands/game/ios/app/addTester.js +11 -12
  58. package/dist/commands/game/ios/app/create.js +4 -5
  59. package/dist/commands/game/ios/app/status.js +7 -8
  60. package/dist/commands/game/ios/app/sync.js +5 -6
  61. package/dist/commands/game/ios/profile/create.js +7 -8
  62. package/dist/commands/game/ios/profile/export.js +6 -7
  63. package/dist/commands/game/ios/profile/import.js +6 -7
  64. package/dist/commands/game/ios/profile/status.js +6 -7
  65. package/dist/commands/game/ios/status.js +9 -10
  66. package/dist/commands/game/ios/wizard.js +5 -6
  67. package/dist/commands/game/job/list.js +4 -5
  68. package/dist/commands/game/job/status.js +7 -8
  69. package/dist/commands/game/list.js +11 -10
  70. package/dist/commands/game/ship.js +18 -13
  71. package/dist/commands/game/status.js +6 -7
  72. package/dist/commands/game/wizard.js +19 -19
  73. package/dist/commands/internal/fastlane.js +12 -1
  74. package/dist/commands/internal/readme.js +12 -715
  75. package/dist/commands/login.js +26 -4
  76. package/dist/commands/status.js +12 -14
  77. package/dist/{export-B5Yfd9vw.js → export-Bd552LBe.js} +1 -1
  78. package/dist/{import-A2WcStHl.js → import-D-EL9sQJ.js} +1 -1
  79. package/dist/{index-CgzANgJt.js → index-1H48f5j2.js} +1 -1
  80. package/dist/index-BtPf4vzY.js +1903 -0
  81. package/dist/{index-Bz1qt_8T.js → index-DCN43FhY.js} +5 -11
  82. package/dist/{index-BBLtvl1Y.js → index-DwATmUTQ.js} +57 -16
  83. package/dist/{upload-BIsFZzBO.js → upload-Dm38PqhN.js} +1 -1
  84. package/dist/{useAppleApp-BZR94exU.js → useAppleApp-BKPntZPm.js} +1 -1
  85. package/dist/{useAppleBundleId-Dg5DsItN.js → useAppleBundleId-DvQKEEy4.js} +1 -1
  86. package/dist/useGoogleStatus-D9jjGa--.js +9 -0
  87. package/dist/{useProjectCredentials-jQYGcDhT.js → useProjectCredentials-BjsS28hP.js} +12 -11
  88. package/dist/{useWebSocket-CIxkPaYi.js → useWebSocket-CIeyHqxG.js} +1 -1
  89. package/docs/README.md +3 -2
  90. package/docs/apiKey.md +12 -2
  91. package/docs/assets/st.png +0 -0
  92. package/docs/game/android/apiKey/policy.md +28 -0
  93. package/docs/game/android/keyStore.md +14 -4
  94. package/docs/game/android/status.md +4 -0
  95. package/docs/game/android.md +9 -305
  96. package/docs/game/ship.md +43 -11
  97. package/docs/game.md +7 -1
  98. package/docs/login.md +6 -2
  99. package/docs/status.md +1 -1
  100. package/package.json +10 -2
  101. package/dist/index-CA6-uLMn.js +0 -221
  102. package/dist/index-CO_ssVFA.js +0 -772
  103. package/dist/index-CYjZ26If.js +0 -153
  104. package/dist/useAndroidServiceAccountTestResult-DueKynFy.js +0 -50
  105. /package/assets/markdown/{create-or-import-keystore.md → create-or-import-keystore.md.ejs} +0 -0
@@ -1,7 +1,6 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import axios from 'axios';
3
- import { W as WEB_URL, V as BaseCommand, o as API_URL, $ as setAuthToken, a0 as acceptTerms } from '../index-CO_ssVFA.js';
4
- import { a as getInput } from '../index-CYjZ26If.js';
3
+ import { W as WEB_URL, ac as BaseCommand, ai as acceptTerms, s as API_URL, aj as setAuthToken, e as getInput } from '../index-BtPf4vzY.js';
5
4
  import 'node:fs';
6
5
  import 'crypto-js';
7
6
  import 'uuid';
@@ -22,6 +21,17 @@ import 'yazl';
22
21
  import 'socket.io-client';
23
22
  import 'fullscreen-ink';
24
23
  import 'ink';
24
+ import 'react/jsx-runtime';
25
+ import 'ink-spinner';
26
+ import 'string-length';
27
+ import 'strip-ansi';
28
+ import 'open';
29
+ import '@inkjs/ui';
30
+ import 'fs';
31
+ import 'path';
32
+ import 'marked';
33
+ import 'marked-terminal';
34
+ import 'qrcode';
25
35
 
26
36
  const TERMS_URL = new URL("/terms", WEB_URL).href;
27
37
  const PRIVACY_URL = new URL("/privacy", WEB_URL).href;
@@ -30,18 +40,29 @@ class Login extends BaseCommand {
30
40
  static description = "Authenticate - will create a new account if one does not exist.";
31
41
  static examples = [
32
42
  "<%= config.bin %> <%= command.id %>",
33
- "<%= config.bin %> <%= command.id %> --force --email me@email.nowhere"
43
+ "<%= config.bin %> <%= command.id %> --force --email me@email.nowhere",
44
+ "<%= config.bin %> <%= command.id %> --acceptAgreements"
34
45
  ];
35
46
  static flags = {
36
47
  email: Flags.string({
37
48
  char: "e",
38
49
  description: "Your email address"
39
50
  }),
40
- force: Flags.boolean({ char: "f" })
51
+ force: Flags.boolean({ char: "f" }),
52
+ acceptAgreements: Flags.boolean({
53
+ description: "Accept the current version of the agreements (terms & privacy).",
54
+ default: false
55
+ })
41
56
  };
42
57
  async run() {
43
58
  const { flags } = this;
44
59
  const authConfig = await this.getAuthConfig();
60
+ if (flags.acceptAgreements) {
61
+ if (authConfig.shipThisUser) {
62
+ await acceptTerms();
63
+ return this.log("You have accepted the latest terms and privacy policy.");
64
+ }
65
+ }
45
66
  if (authConfig.shipThisUser && !flags.force) {
46
67
  throw new Error(
47
68
  `You are already logged in as ${authConfig.shipThisUser.email} use --force to login as a different user or remove the auth file`
@@ -65,6 +86,7 @@ class Login extends BaseCommand {
65
86
  const source = `shipthis-cli-${this.config.version}`;
66
87
  const { data: shipThisUser } = await axios.post(`${API_URL}/auth/email/verify`, { email, otp, source });
67
88
  const getAcceptedTermsResponse = async () => {
89
+ if (flags.acceptAgreements) return true;
68
90
  console.log(
69
91
  `Please review the following documents:
70
92
 
@@ -1,6 +1,6 @@
1
1
  import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { render } from 'ink';
3
- import { V as BaseCommand, j as isCWDGodotGame } from '../index-CO_ssVFA.js';
3
+ import { ac as BaseCommand, m as isCWDGodotGame } from '../index-BtPf4vzY.js';
4
4
  import 'ink-spinner';
5
5
  import 'node:crypto';
6
6
  import 'node:fs';
@@ -29,15 +29,15 @@ import 'marked';
29
29
  import 'marked-terminal';
30
30
  import { N as NextSteps } from '../NextSteps-DbJHmscQ.js';
31
31
  import 'qrcode';
32
- import '../index-CA6-uLMn.js';
33
- import { C as Command } from '../Command-VWMnGslo.js';
32
+ import { C as Command } from '../Command-DhAVAdiI.js';
33
+ import chalk from 'chalk';
34
34
  import '@expo/apple-utils/build/index.js';
35
35
  import 'isomorphic-git';
36
36
  import 'deepmerge';
37
37
  import 'ini';
38
+ import 'fs';
39
+ import 'path';
38
40
  import '../Title-BCQtayg6.js';
39
- import '../index-CYjZ26If.js';
40
- import '../useAndroidServiceAccountTestResult-DueKynFy.js';
41
41
 
42
42
  class Status extends BaseCommand {
43
43
  static args = {};
@@ -47,6 +47,7 @@ class Status extends BaseCommand {
47
47
  async run() {
48
48
  const authConfig = await this.getAuthConfig();
49
49
  const isLoggedIn = Boolean(authConfig.shipThisUser);
50
+ const email = authConfig.shipThisUser?.email;
50
51
  const isGodotGame = isCWDGodotGame();
51
52
  const isShipThisConfigured = await this.hasProjectConfig();
52
53
  const isGitRepo = await isCWDGitRepo();
@@ -56,15 +57,12 @@ class Status extends BaseCommand {
56
57
  if (!isShipThisConfigured) steps.push("shipthis game wizard");
57
58
  const exitCode = steps.length > 0 ? 1 : 0;
58
59
  if (steps.length === 0) steps = ["shipthis game status"];
59
- const statusProps = {
60
- statuses: {
61
- "Git repository detected (not required)": isGitRepo,
62
- "Godot project detected": isGodotGame,
63
- "Logged in": isLoggedIn,
64
- "ShipThis project configured": isShipThisConfigured
65
- },
66
- title: "Status"
67
- };
60
+ const statuses = {};
61
+ statuses[email ? `Logged in ${chalk.bold(email)}` : "Logged in"] = isLoggedIn;
62
+ statuses["Godot project detected"] = isGodotGame;
63
+ statuses["ShipThis project configured"] = isShipThisConfigured;
64
+ statuses["Git repository detected (not required)"] = isGitRepo;
65
+ const statusProps = { statuses, title: "Status" };
68
66
  render(
69
67
  /* @__PURE__ */ jsxs(Command, { command: this, children: [
70
68
  /* @__PURE__ */ jsx(StatusTable, { ...statusProps }),
@@ -1,6 +1,6 @@
1
1
  import * as fs from 'node:fs';
2
2
  import axios from 'axios';
3
- import { o as API_URL, p as getAuthedHeaders } from './index-CO_ssVFA.js';
3
+ import { s as API_URL, t as getAuthedHeaders } from './index-BtPf4vzY.js';
4
4
 
5
5
  async function exportCredential({ credentialId, projectId, zipPath }) {
6
6
  const headers = getAuthedHeaders();
@@ -1,6 +1,6 @@
1
1
  import { promises } from 'node:fs';
2
2
  import axios from 'axios';
3
- import { o as API_URL, p as getAuthedHeaders } from './index-CO_ssVFA.js';
3
+ import { s as API_URL, t as getAuthedHeaders } from './index-BtPf4vzY.js';
4
4
 
5
5
  async function getNewImportTicket(projectId) {
6
6
  const url = projectId ? `${API_URL}/projects/${projectId}/credentials/import/url` : `${API_URL}/credentials/import/url`;
@@ -1,5 +1,5 @@
1
1
  import axios from 'axios';
2
- import { o as API_URL, p as getAuthedHeaders, I as castArrayObjectDates } from './index-CO_ssVFA.js';
2
+ import { s as API_URL, t as getAuthedHeaders, X as castArrayObjectDates } from './index-BtPf4vzY.js';
3
3
  import 'node:fs';
4
4
 
5
5
  async function getUserCredentials(pageSize = 100) {