shipthis 0.1.31 → 0.1.32
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/dist/{AppleBundleIdDetails-eoK5F8Qn.js → AppleBundleIdDetails-6H3cNWxw.js} +17 -19
- package/dist/Command-WPpmLPkL.js +29 -0
- package/dist/CommandGame-cxzWG4nT.js +7 -0
- package/dist/{Create-ISdroJ3G.js → Create-3Ob8sjik.js} +20 -20
- package/dist/GameStatus-BQEtVKvv.js +137 -0
- package/dist/{Import-CfThJF6k.js → Import-CFuPDI0K.js} +33 -35
- package/dist/{JobLogTail-BWzbQBZz.js → JobLogTail-0CBLoG8N.js} +53 -52
- package/dist/{JobProgress-DjIkuk5U.js → JobProgress-lKqVT88m.js} +35 -36
- package/dist/{JobStatusTable-CEqWU73q.js → JobStatusTable-C_ZsZJCm.js} +14 -13
- package/dist/{NextSteps-CK9zHOCt.js → NextSteps-DbJHmscQ.js} +1 -3
- package/dist/{ProgressSpinner-6pw1T8Iw.js → ProgressSpinner-DGcakQSK.js} +1 -1
- package/dist/{ProjectCredentialsTable-u9ruZ9mN.js → ProjectCredentialsTable-B5pHOnGu.js} +11 -10
- package/dist/{StatusTable-Dm5St4g-.js → StatusTable-DzRWcMr4.js} +7 -9
- package/dist/{Table-CvM6pccN.js → Table-FaNgpyeq.js} +15 -15
- package/dist/{UserCredentialsTable-Q7u9M-ap.js → UserCredentialsTable-3W3qesh7.js} +18 -19
- package/dist/{baseAppleCommand-zhkGlKq0.js → baseAppleCommand-BGV088--.js} +1 -1
- package/dist/{baseGameAndroidCommand-DJ-cMLa_.js → baseGameAndroidCommand-CsemgVjp.js} +23 -23
- package/dist/commands/apple/apiKey/create.js +35 -35
- package/dist/commands/apple/apiKey/export.js +26 -26
- package/dist/commands/apple/apiKey/import.js +27 -27
- package/dist/commands/apple/apiKey/status.js +31 -31
- package/dist/commands/apple/certificate/create.js +39 -39
- package/dist/commands/apple/certificate/export.js +26 -26
- package/dist/commands/apple/certificate/import.js +27 -27
- package/dist/commands/apple/certificate/status.js +31 -31
- package/dist/commands/apple/login.js +15 -16
- package/dist/commands/apple/status.js +27 -27
- package/dist/commands/dashboard.js +10 -11
- package/dist/commands/game/android/apiKey/connect.js +28 -28
- package/dist/commands/game/android/apiKey/create.js +28 -28
- package/dist/commands/game/android/apiKey/export.js +29 -29
- package/dist/commands/game/android/apiKey/import.js +31 -31
- package/dist/commands/game/android/apiKey/invite.js +14 -15
- package/dist/commands/game/android/apiKey/status.js +29 -29
- package/dist/commands/game/android/keyStore/create.js +24 -24
- package/dist/commands/game/android/keyStore/export.js +28 -28
- package/dist/commands/game/android/keyStore/import.js +35 -35
- package/dist/commands/game/android/keyStore/status.js +26 -26
- package/dist/commands/game/android/status.js +14 -58
- package/dist/commands/game/build/download.js +24 -24
- package/dist/commands/game/build/list.js +37 -37
- package/dist/commands/game/create.js +15 -16
- package/dist/commands/game/details.js +35 -36
- package/dist/commands/game/export.js +12 -13
- package/dist/commands/game/ios/app/addTester.js +24 -24
- package/dist/commands/game/ios/app/create.js +24 -24
- package/dist/commands/game/ios/app/status.js +29 -29
- package/dist/commands/game/ios/app/sync.js +31 -31
- package/dist/commands/game/ios/profile/create.js +30 -30
- package/dist/commands/game/ios/profile/export.js +28 -28
- package/dist/commands/game/ios/profile/import.js +32 -32
- package/dist/commands/game/ios/profile/status.js +36 -36
- package/dist/commands/game/ios/status.js +46 -58
- package/dist/commands/game/ios/wizard.js +31 -31
- package/dist/commands/game/job/list.js +34 -34
- package/dist/commands/game/job/status.js +31 -31
- package/dist/commands/game/list.js +37 -39
- package/dist/commands/game/ship.js +73 -71
- package/dist/commands/game/status.js +38 -85
- package/dist/commands/game/wizard.js +250 -239
- package/dist/commands/internal/fastlane.js +15 -18
- package/dist/commands/internal/readme.js +38 -37
- package/dist/commands/login.js +14 -15
- package/dist/commands/status.js +32 -30
- package/dist/{export-DZxo2_e_.js → export-CXsVPXA1.js} +5 -5
- package/dist/{git-DREGq-jc.js → git-BpsfNFZ_.js} +8 -8
- package/dist/{import-8pL1AF47.js → import-DGvG5REx.js} +14 -14
- package/dist/{index-w3lHxk5O.js → index-BhhiXbey.js} +240 -224
- package/dist/{index-BHh0BZvD.js → index-C03TV1_J.js} +37 -55
- package/dist/{index-CyvGh-kt.js → index-C66Dd8Xc.js} +77 -87
- package/dist/{index-DJ078v-U.js → index-CGBdOm1q.js} +43 -28
- package/dist/{index-DKQjnJrC.js → index-CS9Gwcb0.js} +41 -43
- package/dist/{index-C6aAyrXW.js → index-CtTI85m-.js} +6 -6
- package/dist/{upload-BTpxj3QP.js → upload-8y5MQEm9.js} +22 -22
- package/dist/{useAndroidServiceAccountTestResult-Dy3Ag7_r.js → useAndroidServiceAccountTestResult-DZk5SMxI.js} +11 -13
- package/dist/{useAppleApp-h1Ogi_qc.js → useAppleApp-DWYGURwU.js} +4 -4
- package/dist/{useAppleBundleId-B3TTNap0.js → useAppleBundleId-PsTJ2g1B.js} +6 -6
- package/dist/{useProjectCredentials-DpeXZcHP.js → useProjectCredentials-BEphqa18.js} +10 -12
- package/dist/{useWebSocket-gyuCsore.js → useWebSocket-5PYa2QER.js} +1 -1
- package/dist/utils/help.js +4 -4
- package/package.json +4 -3
- package/dist/Command-DFdHXDiU.js +0 -44
- package/dist/CommandGame-Dif-oSky.js +0 -9
- package/dist/{RunWithSpinner-BVXNWGD3.js → RunWithSpinner-gMVA07bZ.js} +2 -2
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { Box, Text } from 'ink';
|
|
3
|
-
import { useState, useRef, useEffect, useContext } from 'react';
|
|
4
3
|
import Spinner from 'ink-spinner';
|
|
5
|
-
import {
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import 'crypto-js';
|
|
9
|
-
import 'uuid';
|
|
10
|
-
import 'fs';
|
|
11
|
-
import 'luxon';
|
|
12
|
-
import '@inkjs/ui';
|
|
13
|
-
import { useQuery, useQueryClient } from '@tanstack/react-query';
|
|
14
|
-
import 'yazl';
|
|
15
|
-
import 'crypto';
|
|
16
|
-
import 'readline-sync';
|
|
17
|
-
import 'node:readline';
|
|
4
|
+
import { useState, useRef, useEffect, useContext } from 'react';
|
|
5
|
+
import 'node:crypto';
|
|
6
|
+
import 'node:fs';
|
|
18
7
|
import 'node:path';
|
|
8
|
+
import 'node:readline';
|
|
19
9
|
import 'node:url';
|
|
10
|
+
import 'readline-sync';
|
|
11
|
+
import 'luxon';
|
|
12
|
+
import axios from 'axios';
|
|
20
13
|
import 'isomorphic-git';
|
|
14
|
+
import { p as getAuthedHeaders, o as API_URL, a1 as castObjectDates, P as Platform, C as CredentialsType, Q as getGoogleStatus } from './index-BhhiXbey.js';
|
|
21
15
|
import '@oclif/core';
|
|
22
|
-
import {
|
|
16
|
+
import { useQuery, useQueryClient } from '@tanstack/react-query';
|
|
17
|
+
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-DZk5SMxI.js';
|
|
23
18
|
import 'fast-glob';
|
|
19
|
+
import 'uuid';
|
|
20
|
+
import 'yazl';
|
|
24
21
|
import 'socket.io-client';
|
|
25
|
-
import
|
|
26
|
-
import { u as
|
|
22
|
+
import 'fullscreen-ink';
|
|
23
|
+
import { u as useWebSocket } from './useWebSocket-5PYa2QER.js';
|
|
24
|
+
import { u as useProjectCredentials } from './useProjectCredentials-BEphqa18.js';
|
|
25
|
+
import 'crypto-js';
|
|
26
|
+
import 'string-length';
|
|
27
|
+
import 'strip-ansi';
|
|
27
28
|
import 'open';
|
|
29
|
+
import '@inkjs/ui';
|
|
28
30
|
import 'marked';
|
|
29
31
|
import 'marked-terminal';
|
|
30
|
-
import '
|
|
31
|
-
import { P as ProgressSpinner } from './ProgressSpinner-6pw1T8Iw.js';
|
|
32
|
+
import { P as ProgressSpinner } from './ProgressSpinner-DGcakQSK.js';
|
|
32
33
|
import 'qrcode';
|
|
33
|
-
import '
|
|
34
|
-
import 'strip-ansi';
|
|
34
|
+
import { G as GameContext } from './index-C66Dd8Xc.js';
|
|
35
35
|
|
|
36
36
|
async function fetchStatus({ projectId }) {
|
|
37
37
|
try {
|
|
@@ -45,37 +45,35 @@ async function fetchStatus({ projectId }) {
|
|
|
45
45
|
throw error;
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
|
-
const useAndroidServiceAccountSetupStatus = (props) => {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
});
|
|
56
|
-
};
|
|
48
|
+
const useAndroidServiceAccountSetupStatus = (props) => useQuery({
|
|
49
|
+
queryFn: () => fetchStatus(props),
|
|
50
|
+
queryKey: cacheKeys.androidSetupStatus(props),
|
|
51
|
+
// Status changes frequently, so we want to keep it fresh
|
|
52
|
+
refetchInterval: 1e3 * 5,
|
|
53
|
+
staleTime: 1e3 * 5
|
|
54
|
+
});
|
|
57
55
|
|
|
58
56
|
const ERR_NOT_AUTHENTICATED = "You must be connected to Google to create a Service Account Key";
|
|
59
57
|
const useHasServiceAccountKey = (projectId) => {
|
|
60
|
-
const { data, isSuccess } = useProjectCredentials({
|
|
58
|
+
const { data, isSuccess } = useProjectCredentials({ platform: Platform.ANDROID, projectId });
|
|
61
59
|
return isSuccess && data.data.some((cred) => cred.isActive && cred.platform === Platform.ANDROID && cred.type == CredentialsType.KEY);
|
|
62
60
|
};
|
|
63
|
-
const useAndroidServiceAccount = ({
|
|
61
|
+
const useAndroidServiceAccount = ({ onComplete, onError, projectId }) => {
|
|
64
62
|
const queryClient = useQueryClient();
|
|
65
63
|
const [isStarting, setIsStarting] = useState(false);
|
|
66
64
|
const hasServiceAccountKey = useHasServiceAccountKey(projectId);
|
|
67
65
|
const listener = {
|
|
68
|
-
|
|
69
|
-
eventHandler: async (pattern, data) => {
|
|
66
|
+
async eventHandler(pattern, data) {
|
|
70
67
|
const key = cacheKeys.androidSetupStatus({ projectId });
|
|
71
68
|
queryClient.setQueryData(key, () => data);
|
|
72
|
-
}
|
|
69
|
+
},
|
|
70
|
+
getPattern: () => `project.${projectId}:android-setup-status`
|
|
73
71
|
};
|
|
74
72
|
useWebSocket([listener]);
|
|
75
73
|
const { data: setupStatus } = useAndroidServiceAccountSetupStatus({ projectId });
|
|
76
74
|
const prevSetupStatusRef = useRef("unknown");
|
|
77
75
|
useEffect(() => {
|
|
78
|
-
if (["
|
|
76
|
+
if (["queued", "running"].includes(prevSetupStatusRef.current)) {
|
|
79
77
|
if (setupStatus?.status === "complete") onComplete();
|
|
80
78
|
if (setupStatus?.status === "error") onError(new Error(setupStatus.errorMessage));
|
|
81
79
|
}
|
|
@@ -91,7 +89,7 @@ const useAndroidServiceAccount = ({ projectId, onError, onComplete }) => {
|
|
|
91
89
|
const startUrl = `${androidKeyApiBase}/setup/`;
|
|
92
90
|
const { data: updatedStatus } = await axios.post(startUrl, {}, { headers });
|
|
93
91
|
queryClient.invalidateQueries({
|
|
94
|
-
queryKey: cacheKeys.projectCredentials({
|
|
92
|
+
queryKey: cacheKeys.projectCredentials({ pageNumber: 0, projectId })
|
|
95
93
|
});
|
|
96
94
|
await queryClient.setQueryData(cacheKeys.androidSetupStatus({ projectId }), (_) => updatedStatus);
|
|
97
95
|
setIsStarting(false);
|
|
@@ -106,9 +104,9 @@ const useAndroidServiceAccount = ({ projectId, onError, onComplete }) => {
|
|
|
106
104
|
const isCreating = isStarting || setupStatus?.status === "queued" || setupStatus?.status === "running";
|
|
107
105
|
return {
|
|
108
106
|
handleStart,
|
|
109
|
-
|
|
107
|
+
hasServiceAccountKey,
|
|
110
108
|
isCreating,
|
|
111
|
-
|
|
109
|
+
setupStatus
|
|
112
110
|
};
|
|
113
111
|
};
|
|
114
112
|
|
|
@@ -116,12 +114,12 @@ const CreateServiceAccountKey = (props) => {
|
|
|
116
114
|
const { gameId } = useContext(GameContext);
|
|
117
115
|
return /* @__PURE__ */ jsx(Fragment, { children: gameId && /* @__PURE__ */ jsx(CreateForGame, { gameId, ...props }) });
|
|
118
116
|
};
|
|
119
|
-
const CreateForGame = ({ onComplete, onError,
|
|
117
|
+
const CreateForGame = ({ gameId, onComplete, onError, ...boxProps }) => {
|
|
120
118
|
const [didStart, setDidStart] = useState(false);
|
|
121
|
-
const { handleStart,
|
|
122
|
-
|
|
119
|
+
const { handleStart, isCreating, setupStatus } = useAndroidServiceAccount({
|
|
120
|
+
onComplete,
|
|
123
121
|
onError,
|
|
124
|
-
|
|
122
|
+
projectId: gameId
|
|
125
123
|
});
|
|
126
124
|
useEffect(() => {
|
|
127
125
|
handleStart().then(() => setDidStart(true));
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
import axios from 'axios';
|
|
2
|
-
import {
|
|
3
|
-
import 'fs';
|
|
2
|
+
import { o as API_URL, p as getAuthedHeaders, I as castArrayObjectDates } from './index-BhhiXbey.js';
|
|
3
|
+
import 'node:fs';
|
|
4
4
|
|
|
5
5
|
async function getUserCredentials(pageSize = 100) {
|
|
6
6
|
const headers = getAuthedHeaders();
|
|
7
7
|
const { data } = await axios({
|
|
8
|
+
headers,
|
|
8
9
|
method: "get",
|
|
9
|
-
url: `${API_URL}/credentials?pageSize=${pageSize}
|
|
10
|
-
headers
|
|
10
|
+
url: `${API_URL}/credentials?pageSize=${pageSize}`
|
|
11
11
|
});
|
|
12
12
|
return castArrayObjectDates(data.data);
|
|
13
13
|
}
|
|
14
14
|
async function getProjectCredentials(projectId, pageSize = 100) {
|
|
15
15
|
const headers = getAuthedHeaders();
|
|
16
16
|
const { data } = await axios({
|
|
17
|
+
headers,
|
|
17
18
|
method: "get",
|
|
18
|
-
url: `${API_URL}/projects/${projectId}/credentials?pageSize=${pageSize}
|
|
19
|
-
headers
|
|
19
|
+
url: `${API_URL}/projects/${projectId}/credentials?pageSize=${pageSize}`
|
|
20
20
|
});
|
|
21
21
|
return castArrayObjectDates(data.data);
|
|
22
22
|
}
|
|
@@ -1,59 +1,59 @@
|
|
|
1
1
|
import axios from 'axios';
|
|
2
|
-
import {
|
|
2
|
+
import { o as API_URL, p as getAuthedHeaders } from './index-BhhiXbey.js';
|
|
3
3
|
|
|
4
4
|
async function getNewUploadTicket(projectId = null) {
|
|
5
5
|
const url = projectId ? `${API_URL}/projects/${projectId}/credentials/url` : `${API_URL}/credentials/url`;
|
|
6
6
|
const headers = getAuthedHeaders();
|
|
7
7
|
const { data: uploadInfo } = await axios({
|
|
8
|
+
headers,
|
|
8
9
|
method: "post",
|
|
9
|
-
url
|
|
10
|
-
headers
|
|
10
|
+
url
|
|
11
11
|
});
|
|
12
12
|
return uploadInfo;
|
|
13
13
|
}
|
|
14
|
-
async function uploadUserCredentials({ contents, platform,
|
|
14
|
+
async function uploadUserCredentials({ contents, platform, serialNumber, type }) {
|
|
15
15
|
const uploadInfo = await getNewUploadTicket();
|
|
16
16
|
const jsonBuffer = Buffer.from(JSON.stringify(contents));
|
|
17
17
|
await axios.put(uploadInfo.url, jsonBuffer, {
|
|
18
18
|
headers: {
|
|
19
|
-
"Content-
|
|
20
|
-
"Content-
|
|
19
|
+
"Content-Type": "application/json",
|
|
20
|
+
"Content-length": jsonBuffer.length
|
|
21
21
|
}
|
|
22
22
|
});
|
|
23
23
|
const headers = getAuthedHeaders();
|
|
24
24
|
return await axios({
|
|
25
|
-
method: "post",
|
|
26
|
-
url: `${API_URL}/credentials`,
|
|
27
|
-
headers,
|
|
28
25
|
data: {
|
|
29
26
|
platform,
|
|
27
|
+
serialNumber,
|
|
30
28
|
type,
|
|
31
|
-
uuid: uploadInfo.uuid
|
|
32
|
-
|
|
33
|
-
|
|
29
|
+
uuid: uploadInfo.uuid
|
|
30
|
+
},
|
|
31
|
+
headers,
|
|
32
|
+
method: "post",
|
|
33
|
+
url: `${API_URL}/credentials`
|
|
34
34
|
});
|
|
35
35
|
}
|
|
36
|
-
async function uploadProjectCredentials(projectId, { contents,
|
|
36
|
+
async function uploadProjectCredentials(projectId, { contents, identifier, platform, serialNumber, type }) {
|
|
37
37
|
const uploadInfo = await getNewUploadTicket(projectId);
|
|
38
38
|
const jsonBuffer = Buffer.from(JSON.stringify(contents));
|
|
39
39
|
await axios.put(uploadInfo.url, jsonBuffer, {
|
|
40
40
|
headers: {
|
|
41
|
-
"Content-
|
|
42
|
-
"Content-
|
|
41
|
+
"Content-Type": "application/json",
|
|
42
|
+
"Content-length": jsonBuffer.length
|
|
43
43
|
}
|
|
44
44
|
});
|
|
45
45
|
const headers = getAuthedHeaders();
|
|
46
46
|
return await axios({
|
|
47
|
-
method: "post",
|
|
48
|
-
url: `${API_URL}/projects/${projectId}/credentials`,
|
|
49
|
-
headers,
|
|
50
47
|
data: {
|
|
48
|
+
identifier,
|
|
51
49
|
platform,
|
|
50
|
+
serialNumber,
|
|
52
51
|
type,
|
|
53
|
-
uuid: uploadInfo.uuid
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
52
|
+
uuid: uploadInfo.uuid
|
|
53
|
+
},
|
|
54
|
+
headers,
|
|
55
|
+
method: "post",
|
|
56
|
+
url: `${API_URL}/projects/${projectId}/credentials`
|
|
57
57
|
});
|
|
58
58
|
}
|
|
59
59
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { p as getAuthedHeaders, q as API_URL } from './index-w3lHxk5O.js';
|
|
2
|
-
import axios from 'axios';
|
|
3
1
|
import { useQuery } from '@tanstack/react-query';
|
|
2
|
+
import axios from 'axios';
|
|
3
|
+
import { o as API_URL, p as getAuthedHeaders } from './index-BhhiXbey.js';
|
|
4
4
|
|
|
5
5
|
const cacheKeys = {
|
|
6
6
|
androidKeyTestResult: (props) => ["androidKeyTestResult", ...Object.values(props)],
|
|
@@ -15,21 +15,21 @@ const cacheKeys = {
|
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
var KeyTestStatus = /* @__PURE__ */ ((KeyTestStatus2) => {
|
|
18
|
-
KeyTestStatus2["SUCCESS"] = "success";
|
|
19
18
|
KeyTestStatus2["ERROR"] = "error";
|
|
19
|
+
KeyTestStatus2["SUCCESS"] = "success";
|
|
20
20
|
return KeyTestStatus2;
|
|
21
21
|
})(KeyTestStatus || {});
|
|
22
22
|
var KeyTestError = /* @__PURE__ */ ((KeyTestError2) => {
|
|
23
|
-
KeyTestError2["NO_SERVICE_ACCOUNT_KEY"] = "no_service_account_key";
|
|
24
|
-
KeyTestError2["NO_PACKAGE_NAME"] = "no_package_name";
|
|
25
23
|
KeyTestError2["APP_NOT_FOUND"] = "app_not_found";
|
|
24
|
+
KeyTestError2["NO_PACKAGE_NAME"] = "no_package_name";
|
|
25
|
+
KeyTestError2["NO_SERVICE_ACCOUNT_KEY"] = "no_service_account_key";
|
|
26
26
|
KeyTestError2["NOT_INVITED"] = "not_invited";
|
|
27
27
|
return KeyTestError2;
|
|
28
28
|
})(KeyTestError || {});
|
|
29
29
|
const KeyTestErrorMessage = {
|
|
30
|
-
["no_service_account_key" /* NO_SERVICE_ACCOUNT_KEY */]: "Service Account API Key not found in your account",
|
|
31
|
-
["no_package_name" /* NO_PACKAGE_NAME */]: "Android Package Name has not been set",
|
|
32
30
|
["app_not_found" /* APP_NOT_FOUND */]: "Application not found in Google Play Console",
|
|
31
|
+
["no_package_name" /* NO_PACKAGE_NAME */]: "Android Package Name has not been set",
|
|
32
|
+
["no_service_account_key" /* NO_SERVICE_ACCOUNT_KEY */]: "Service Account API Key not found in your account",
|
|
33
33
|
["not_invited" /* NOT_INVITED */]: "Service Account has not been invited to Google Play"
|
|
34
34
|
};
|
|
35
35
|
function niceError(keyError) {
|
|
@@ -42,11 +42,9 @@ const fetchKeyTestResult = async ({ projectId }, config) => {
|
|
|
42
42
|
const { data } = await axios.post(url, {}, { headers, ...config });
|
|
43
43
|
return data;
|
|
44
44
|
};
|
|
45
|
-
const useAndroidServiceAccountTestResult = (props) => {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
});
|
|
50
|
-
};
|
|
45
|
+
const useAndroidServiceAccountTestResult = (props) => useQuery({
|
|
46
|
+
queryFn: () => fetchKeyTestResult(props),
|
|
47
|
+
queryKey: cacheKeys.androidKeyTestResult(props)
|
|
48
|
+
});
|
|
51
49
|
|
|
52
50
|
export { KeyTestStatus as K, KeyTestError as a, cacheKeys as c, fetchKeyTestResult as f, niceError as n, useAndroidServiceAccountTestResult as u };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useQuery } from '@tanstack/react-query';
|
|
2
|
-
import { f as App } from './index-
|
|
2
|
+
import { f as App } from './index-BhhiXbey.js';
|
|
3
3
|
|
|
4
4
|
const queryAppleApp = async ({ ctx, iosBundleId }) => {
|
|
5
5
|
if (!iosBundleId) {
|
|
@@ -14,17 +14,17 @@ const queryAppleApp = async ({ ctx, iosBundleId }) => {
|
|
|
14
14
|
return {
|
|
15
15
|
app,
|
|
16
16
|
summary: {
|
|
17
|
+
bundleId: app.attributes.bundleId,
|
|
17
18
|
id: app.id,
|
|
18
19
|
name: app.attributes.name,
|
|
19
|
-
bundleId: app.attributes.bundleId,
|
|
20
20
|
primaryLocale: app.attributes.primaryLocale
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
23
|
};
|
|
24
24
|
const useAppleApp = (props) => {
|
|
25
25
|
const queryResult = useQuery({
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
queryFn: () => queryAppleApp(props),
|
|
27
|
+
queryKey: ["appleApp", props.iosBundleId]
|
|
28
28
|
});
|
|
29
29
|
return queryResult;
|
|
30
30
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useQuery } from '@tanstack/react-query';
|
|
2
|
-
import { e as BundleId,
|
|
2
|
+
import { e as BundleId, q as getGodotProjectCapabilities, P as Platform, G as GODOT_CAPABILITIES, r as CapabilityType } from './index-BhhiXbey.js';
|
|
3
3
|
|
|
4
4
|
async function getBundleIdCapabilities(bundleId) {
|
|
5
5
|
const current = await bundleId.getBundleIdCapabilitiesAsync();
|
|
6
|
-
|
|
6
|
+
const existing = [];
|
|
7
7
|
for (const capability of current) {
|
|
8
8
|
const capabilityType = Object.values(CapabilityType).find((c) => capability.isType(c));
|
|
9
9
|
if (capabilityType) {
|
|
@@ -33,10 +33,10 @@ const fetchBundleId = async ({ ctx, iosBundleId }) => {
|
|
|
33
33
|
const isEnabledInProject = projectCapabilities.includes(gc.type);
|
|
34
34
|
const isCorrectlyConfigured = isEnabledInBundle === isEnabledInProject;
|
|
35
35
|
return {
|
|
36
|
-
|
|
36
|
+
isCorrectlyConfigured,
|
|
37
37
|
isEnabledInBundle,
|
|
38
38
|
isEnabledInProject,
|
|
39
|
-
|
|
39
|
+
name: gc.name
|
|
40
40
|
};
|
|
41
41
|
});
|
|
42
42
|
return {
|
|
@@ -55,8 +55,8 @@ const fetchBundleId = async ({ ctx, iosBundleId }) => {
|
|
|
55
55
|
};
|
|
56
56
|
const useAppleBundleId = (props) => {
|
|
57
57
|
const queryResult = useQuery({
|
|
58
|
-
|
|
59
|
-
|
|
58
|
+
queryFn: () => fetchBundleId(props),
|
|
59
|
+
queryKey: ["appleBundleId", props.iosBundleId]
|
|
60
60
|
});
|
|
61
61
|
return queryResult;
|
|
62
62
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import axios from 'axios';
|
|
2
1
|
import { useQuery } from '@tanstack/react-query';
|
|
3
|
-
import
|
|
4
|
-
import { b as getShortDate, p as getAuthedHeaders,
|
|
5
|
-
import {
|
|
2
|
+
import axios from 'axios';
|
|
3
|
+
import { b as getShortDate, p as getAuthedHeaders, o as API_URL, I as castArrayObjectDates } from './index-BhhiXbey.js';
|
|
4
|
+
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-DZk5SMxI.js';
|
|
5
|
+
import { g as getShortUUID } from './index-CGBdOm1q.js';
|
|
6
6
|
|
|
7
7
|
async function queryProjectCredentials({
|
|
8
8
|
projectId,
|
|
@@ -23,11 +23,11 @@ async function queryProjectCredentials({
|
|
|
23
23
|
}
|
|
24
24
|
function getProjectCredentialSummary(credential) {
|
|
25
25
|
return {
|
|
26
|
+
createdAt: getShortDate(credential.createdAt),
|
|
26
27
|
id: getShortUUID(credential.id),
|
|
27
|
-
type: credential.type,
|
|
28
|
-
serial: credential.serialNumber.substring(0, 30) + (credential.serialNumber.length > 30 ? "\u2026" : ""),
|
|
29
28
|
isActive: credential.isActive,
|
|
30
|
-
|
|
29
|
+
serial: credential.serialNumber.slice(0, 30) + (credential.serialNumber.length > 30 ? "\u2026" : ""),
|
|
30
|
+
type: credential.type
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
33
|
const useProjectCredentials = ({
|
|
@@ -36,15 +36,13 @@ const useProjectCredentials = ({
|
|
|
36
36
|
...fetchProps
|
|
37
37
|
}) => {
|
|
38
38
|
const queryResult = useQuery({
|
|
39
|
-
queryKey: cacheKeys.projectCredentials(fetchProps),
|
|
40
39
|
queryFn: async () => queryProjectCredentials(fetchProps),
|
|
41
|
-
|
|
40
|
+
queryKey: cacheKeys.projectCredentials(fetchProps),
|
|
41
|
+
select(data) {
|
|
42
42
|
if (!(platform || type)) return data;
|
|
43
43
|
return {
|
|
44
44
|
...data,
|
|
45
|
-
data: data.data.filter((credential) =>
|
|
46
|
-
return (!platform || credential.platform === platform) && (!type || credential.type === type);
|
|
47
|
-
})
|
|
45
|
+
data: data.data.filter((credential) => (!platform || credential.platform === platform) && (!type || credential.type === type))
|
|
48
46
|
};
|
|
49
47
|
}
|
|
50
48
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useEffect } from 'react';
|
|
2
2
|
import { io } from 'socket.io-client';
|
|
3
|
-
import {
|
|
3
|
+
import { N as WS_URL, O as getAuthToken } from './index-BhhiXbey.js';
|
|
4
4
|
|
|
5
5
|
function useWebSocket(listeners = []) {
|
|
6
6
|
const log = () => {
|
package/dist/utils/help.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { Help } from '@oclif/core';
|
|
2
2
|
|
|
3
3
|
class CustomHelp extends Help {
|
|
4
|
-
formatTopics(topics) {
|
|
5
|
-
const publicTopics = topics.filter((t) => t.name !== "internal");
|
|
6
|
-
return super.formatTopics(publicTopics);
|
|
7
|
-
}
|
|
8
4
|
// formatCommand is protected, so we need to override it to make it public
|
|
9
5
|
exposedFormatCommand(command) {
|
|
10
6
|
return super.formatCommand(command);
|
|
11
7
|
}
|
|
8
|
+
formatTopics(topics) {
|
|
9
|
+
const publicTopics = topics.filter((t) => t.name !== "internal");
|
|
10
|
+
return super.formatTopics(publicTopics);
|
|
11
|
+
}
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
export { CustomHelp as default };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "shipthis",
|
|
3
3
|
"description": "ShipThis manages building and uploading your Godot games to the App Store and Google Play.",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.32",
|
|
5
5
|
"author": "Hello Invent Ltd",
|
|
6
6
|
"bin": {
|
|
7
7
|
"shipthis": "./bin/run.js"
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"deepmerge": "^4.3.1",
|
|
23
23
|
"fast-glob": "^3.3.2",
|
|
24
24
|
"fs-extra": "^11.2.0",
|
|
25
|
-
"fullscreen-ink": "^0.0
|
|
25
|
+
"fullscreen-ink": "^0.1.0",
|
|
26
26
|
"ini": "^5.0.0",
|
|
27
27
|
"ink": "^5.0.1",
|
|
28
28
|
"ink-spinner": "^5.0.0",
|
|
@@ -70,6 +70,7 @@
|
|
|
70
70
|
"eslint-config-oclif": "^5",
|
|
71
71
|
"eslint-config-oclif-typescript": "^3",
|
|
72
72
|
"eslint-config-prettier": "^9",
|
|
73
|
+
"eslint-plugin-import": "^2.32.0",
|
|
73
74
|
"mocha": "^10",
|
|
74
75
|
"oclif": "^4",
|
|
75
76
|
"pkgroll": "^2.4.2",
|
|
@@ -208,7 +209,7 @@
|
|
|
208
209
|
"build-original": "shx rm -rf dist && tsc -b",
|
|
209
210
|
"build-tsc-alias": "shx rm -rf dist && npx tsc --build && npx tsc-alias -p tsconfig.json",
|
|
210
211
|
"build": "pkgroll --clean-dist",
|
|
211
|
-
"lint": "eslint . --ext .ts",
|
|
212
|
+
"lint": "eslint . --ext .ts,.tsx",
|
|
212
213
|
"posttest": "npm run lint",
|
|
213
214
|
"prepack": "cp package-lock.json package-lock.dev.json || true && npm run readme && oclif manifest && npm shrinkwrap",
|
|
214
215
|
"postpack": "mv package-lock.dev.json package-lock.json || true && shx rm -f oclif.manifest.json && shx rm -f npm-shrinkwrap.json",
|
package/dist/Command-DFdHXDiU.js
DELETED
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
import { jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { useStdout, Box } from 'ink';
|
|
3
|
-
import { QueryClientProvider } from '@tanstack/react-query';
|
|
4
|
-
import { _ as queryClient } from './index-w3lHxk5O.js';
|
|
5
|
-
import 'axios';
|
|
6
|
-
import 'crypto';
|
|
7
|
-
import 'fs';
|
|
8
|
-
import 'readline-sync';
|
|
9
|
-
import 'node:readline';
|
|
10
|
-
import 'node:path';
|
|
11
|
-
import 'node:url';
|
|
12
|
-
import 'luxon';
|
|
13
|
-
import 'isomorphic-git';
|
|
14
|
-
import '@oclif/core';
|
|
15
|
-
import { useCallback, useState, useEffect } from 'react';
|
|
16
|
-
import 'crypto-js';
|
|
17
|
-
import 'uuid';
|
|
18
|
-
import 'socket.io-client';
|
|
19
|
-
import 'fast-glob';
|
|
20
|
-
import 'yazl';
|
|
21
|
-
import { C as CommandProvider } from './index-CyvGh-kt.js';
|
|
22
|
-
|
|
23
|
-
function useScreenSize() {
|
|
24
|
-
const { stdout } = useStdout();
|
|
25
|
-
const getSize = useCallback(() => ({ height: stdout.rows, width: stdout.columns }), [stdout]);
|
|
26
|
-
const [size, setSize] = useState(getSize);
|
|
27
|
-
useEffect(() => {
|
|
28
|
-
function onResize() {
|
|
29
|
-
setSize(getSize());
|
|
30
|
-
}
|
|
31
|
-
stdout.on("resize", onResize);
|
|
32
|
-
return () => {
|
|
33
|
-
stdout.off("resize", onResize);
|
|
34
|
-
};
|
|
35
|
-
}, [stdout, getSize]);
|
|
36
|
-
return size;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
const Command = ({ children, command }) => {
|
|
40
|
-
const { width } = useScreenSize();
|
|
41
|
-
return /* @__PURE__ */ jsx(QueryClientProvider, { client: queryClient, children: /* @__PURE__ */ jsx(CommandProvider, { command, children: /* @__PURE__ */ jsx(Box, { width, flexDirection: "column", children }) }) });
|
|
42
|
-
};
|
|
43
|
-
|
|
44
|
-
export { Command as C, useScreenSize as u };
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { G as GameProvider } from './index-CyvGh-kt.js';
|
|
3
|
-
import { C as Command } from './Command-DFdHXDiU.js';
|
|
4
|
-
|
|
5
|
-
const CommandGame = ({ children, command }) => {
|
|
6
|
-
return /* @__PURE__ */ jsx(Command, { command, children: /* @__PURE__ */ jsx(GameProvider, { children }) });
|
|
7
|
-
};
|
|
8
|
-
|
|
9
|
-
export { CommandGame as C };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import React from 'react';
|
|
3
2
|
import { Box, Text } from 'ink';
|
|
4
3
|
import Spinner from 'ink-spinner';
|
|
4
|
+
import React from 'react';
|
|
5
5
|
|
|
6
6
|
const RunWithSpinner = ({
|
|
7
7
|
executeMethod,
|
|
8
|
-
msgInProgress,
|
|
9
8
|
msgComplete,
|
|
9
|
+
msgInProgress,
|
|
10
10
|
onComplete,
|
|
11
11
|
spinnerType
|
|
12
12
|
}) => {
|