shipthis 0.1.10 → 0.1.12
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/assets/markdown/create-or-import-keystore.md +7 -0
- package/dist/{AppleBundleIdDetails-DKeSAte9.js → AppleBundleIdDetails-DymjrhOZ.js} +1 -1
- package/dist/{CommandGame--SAa3wEL.js → CommandGame-C1oTlfdb.js} +1 -1
- package/dist/{CreateKeystore-g1z6DsU5.js → Create-DIaSKUpl.js} +5 -5
- package/dist/Import-BIOsf8AA.js +107 -0
- package/dist/{JobProgress-jmGAzvxS.js → JobProgress-W0QQR49T.js} +2 -2
- package/dist/{JobStatusTable-ByW0bN6c.js → JobStatusTable-DqoppRro.js} +2 -2
- package/dist/commands/apple/apiKey/create.js +4 -4
- package/dist/commands/apple/apiKey/export.js +3 -3
- package/dist/commands/apple/apiKey/import.js +4 -4
- package/dist/commands/apple/apiKey/status.js +3 -3
- package/dist/commands/apple/certificate/create.js +4 -4
- package/dist/commands/apple/certificate/export.js +3 -3
- package/dist/commands/apple/certificate/import.js +4 -4
- package/dist/commands/apple/certificate/status.js +3 -3
- package/dist/commands/apple/status.js +3 -3
- package/dist/commands/game/android/apiKey/connect.js +6 -6
- package/dist/commands/game/android/apiKey/create.js +6 -6
- package/dist/commands/game/android/apiKey/export.js +3 -3
- package/dist/commands/game/android/apiKey/import.js +4 -4
- package/dist/commands/game/android/apiKey/status.js +3 -3
- package/dist/commands/game/android/keyStore/create.js +7 -7
- package/dist/commands/game/android/keyStore/export.js +3 -3
- package/dist/commands/game/android/keyStore/import.js +45 -25
- package/dist/commands/game/android/keyStore/status.js +3 -3
- package/dist/commands/game/android/status.js +5 -5
- package/dist/commands/game/build/download.js +4 -4
- package/dist/commands/game/build/list.js +4 -4
- package/dist/commands/game/details.js +3 -3
- package/dist/commands/game/ios/app/addTester.js +3 -3
- package/dist/commands/game/ios/app/create.js +3 -3
- package/dist/commands/game/ios/app/status.js +4 -4
- package/dist/commands/game/ios/app/sync.js +3 -3
- package/dist/commands/game/ios/profile/create.js +4 -4
- package/dist/commands/game/ios/profile/export.js +3 -3
- package/dist/commands/game/ios/profile/import.js +4 -4
- package/dist/commands/game/ios/profile/status.js +3 -3
- package/dist/commands/game/ios/status.js +6 -6
- package/dist/commands/game/job/list.js +5 -5
- package/dist/commands/game/job/status.js +7 -7
- package/dist/commands/game/list.js +5 -5
- package/dist/commands/game/ship.js +7 -7
- package/dist/commands/game/status.js +5 -5
- package/dist/commands/game/wizard.js +116 -17
- package/dist/commands/status.js +3 -3
- package/dist/{import-7T3J63j2.js → import-v54PM_Qg.js} +11 -2
- package/dist/{index-m4HTrJ5J.js → index-D6BH5UAM.js} +3 -3
- package/dist/{index-DgbQBx6x.js → index-o9Y-84Rj.js} +1 -1
- package/dist/{useJobWatching-D-YzSlK8.js → useJobWatching-I_A3b36f.js} +1 -1
- package/npm-shrinkwrap.json +2 -2
- package/oclif.manifest.json +27 -86
- package/package.json +1 -1
- package/dist/AppleBundleIdDetails-C0XqjxKJ.js +0 -72
- package/dist/AppleBundleIdDetails-CjP5y0cj.js +0 -74
- package/dist/AppleBundleIdDetails-CztWY_mT.js +0 -73
- package/dist/AppleBundleIdDetails-Df30MPFC.js +0 -73
- package/dist/AppleBundleIdDetails-Dxo99Sgu.js +0 -72
- package/dist/Command-1YAl_0zS.js +0 -204
- package/dist/Command-Cl-JfhTy.js +0 -203
- package/dist/Command-Dn0P_KOV.js +0 -205
- package/dist/Command-DxmQn3XT.js +0 -204
- package/dist/Command-YJJp90ru.js +0 -204
- package/dist/CommandGame-CZUx_VQu.js +0 -8
- package/dist/CommandGame-DspVLTPZ.js +0 -8
- package/dist/CommandGame-cPaTk1wh.js +0 -8
- package/dist/CommandGame-k04mHiDl.js +0 -8
- package/dist/CommandGame-pI9VXKxi.js +0 -8
- package/dist/CreateKeystore-BnNdeDUa.js +0 -57
- package/dist/CreateKeystore-BqJdpvsI.js +0 -56
- package/dist/CreateKeystore-Cf-nsK_M.js +0 -56
- package/dist/CreateKeystore-D8uTRamD.js +0 -56
- package/dist/CreateKeystore-Dm0KVh85.js +0 -56
- package/dist/JobProgress-CPkWVSlH.js +0 -108
- package/dist/JobProgress-Dk0UoNah.js +0 -108
- package/dist/JobProgress-biiLhigg.js +0 -109
- package/dist/JobStatusTable-BA_q-kgE.js +0 -75
- package/dist/JobStatusTable-CgaTS7jS.js +0 -75
- package/dist/JobStatusTable-q4atKzhu.js +0 -75
- package/dist/ProjectCredentialsTable-BIWBAXCh.js +0 -37
- package/dist/ProjectCredentialsTable-Ch8022rs.js +0 -37
- package/dist/ProjectCredentialsTable-DRMK_SNw.js +0 -37
- package/dist/ProjectCredentialsTable-DfkpvTf8.js +0 -37
- package/dist/UserCredentialsTable-CeJS3_hd.js +0 -82
- package/dist/UserCredentialsTable-DMh8Wpy7.js +0 -82
- package/dist/UserCredentialsTable-DgHZJSHG.js +0 -82
- package/dist/UserCredentialsTable-ysmM5dlV.js +0 -82
- package/dist/baseAppleCommand-1isaFxCQ.js +0 -10
- package/dist/baseAppleCommand-B3WQtlx-.js +0 -10
- package/dist/baseAppleCommand-D-G4h8zQ.js +0 -10
- package/dist/baseAppleCommand-DpasCbje.js +0 -10
- package/dist/baseGameAndroidCommand-B-CFhPnE.js +0 -43
- package/dist/baseGameAndroidCommand-B3LRG701.js +0 -43
- package/dist/baseGameAndroidCommand-C9BuS2Sr.js +0 -43
- package/dist/baseGameAndroidCommand-DD0H8iy-.js +0 -43
- package/dist/commands/game/android/wizard.js +0 -509
- package/dist/export-BDxGDZdh.js +0 -36
- package/dist/export-B_F6vXIK.js +0 -36
- package/dist/export-BiLHgSJ9.js +0 -36
- package/dist/export-C_lu1FD9.js +0 -36
- package/dist/import-Brg3zYmT.js +0 -38
- package/dist/import-BrlJuE2Z.js +0 -38
- package/dist/import-CxNikF1c.js +0 -38
- package/dist/import-DPbg8WvS.js +0 -38
- package/dist/index-B5XHQfs2.js +0 -122
- package/dist/index-B6V7vGOj.js +0 -136
- package/dist/index-BDFKyTPb.js +0 -24
- package/dist/index-BL-1G60K.js +0 -135
- package/dist/index-BQRxiyqn.js +0 -693
- package/dist/index-BQnkBr1Q.js +0 -136
- package/dist/index-BX9h2vPV.js +0 -123
- package/dist/index-BjGSEqP5.js +0 -135
- package/dist/index-BuZmCvZh.js +0 -24
- package/dist/index-Bv3x8c78.js +0 -693
- package/dist/index-ByOvCs4O.js +0 -122
- package/dist/index-BzffuqPa.js +0 -24
- package/dist/index-C9734Cj2.js +0 -693
- package/dist/index-CKYExssR.js +0 -136
- package/dist/index-CgBgZUkL.js +0 -144
- package/dist/index-DBrQda8r.js +0 -122
- package/dist/index-DE2Hvx2o.js +0 -122
- package/dist/index-DdABTtYO.js +0 -693
- package/dist/index-DxHPjZav.js +0 -136
- package/dist/index-X__XH_Fd.js +0 -144
- package/dist/index-wyPoxiTc.js +0 -136
- package/dist/upload-CMo3hUhl.js +0 -60
- package/dist/upload-Cx71802W.js +0 -60
- package/dist/upload-DvAE1vDq.js +0 -60
- package/dist/upload-LXRr4pMa.js +0 -60
- package/dist/useAndroidServiceAccountTestResult-BDc7XpKE.js +0 -52
- package/dist/useAndroidServiceAccountTestResult-B_ekRewZ.js +0 -52
- package/dist/useAndroidServiceAccountTestResult-D_30xIJA.js +0 -52
- package/dist/useAndroidServiceAccountTestResult-InDf5WSl.js +0 -52
- package/dist/useAppleApp-CApC0-4Q.js +0 -32
- package/dist/useAppleApp-CETIcsJS.js +0 -32
- package/dist/useAppleApp-DgE0wEaq.js +0 -32
- package/dist/useAppleApp-DnSjUfSs.js +0 -32
- package/dist/useAppleBundleId-BNI8swhC.js +0 -64
- package/dist/useAppleBundleId-DtLODy3p.js +0 -64
- package/dist/useAppleBundleId-SmzY6rkm.js +0 -64
- package/dist/useAppleBundleId-gPBzJwQg.js +0 -64
- package/dist/useJobWatching-BIG6fnTN.js +0 -45
- package/dist/useJobWatching-BcBJ5dy1.js +0 -43
- package/dist/useJobWatching-Bz1e6xOv.js +0 -43
- package/dist/useJobWatching-Cp-CYd90.js +0 -45
- package/dist/useJobWatching-P5oC7mNB.js +0 -45
- package/dist/useProjectCredentials-B5ZmpIxL.js +0 -54
- package/dist/useProjectCredentials-BRffcsO3.js +0 -54
- package/dist/useProjectCredentials-CKngz2rd.js +0 -54
- package/dist/useProjectCredentials-EapDge1I.js +0 -54
- package/dist/useWebSocket-Bep1zAVG.js +0 -36
- package/dist/useWebSocket-D8PojLtx.js +0 -36
- package/dist/useWebSocket-DoImIdTy.js +0 -36
- package/dist/useWebSocket-rBLiZsKb.js +0 -36
- package/dist/wizard-ChPegnMW.js +0 -133
- package/dist/{Command-D6rWEZRM.js → Command-BiB9MqbJ.js} +3 -3
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { Box, Text } from 'ink';
|
|
3
|
-
import Spinner from 'ink-spinner';
|
|
4
|
-
import 'crypto';
|
|
5
|
-
import 'fs';
|
|
6
|
-
import 'readline-sync';
|
|
7
|
-
import 'node:readline';
|
|
8
|
-
import 'node:path';
|
|
9
|
-
import 'node:url';
|
|
10
|
-
import 'react';
|
|
11
|
-
import axios from 'axios';
|
|
12
|
-
import { useQuery } from '@tanstack/react-query';
|
|
13
|
-
import { b as getShortDate, p as getAuthedHeaders, q as API_URL, H as castArrayObjectDates } from './index-DdABTtYO.js';
|
|
14
|
-
import 'crypto-js';
|
|
15
|
-
import 'uuid';
|
|
16
|
-
import 'luxon';
|
|
17
|
-
import 'fast-glob';
|
|
18
|
-
import 'yazl';
|
|
19
|
-
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-InDf5WSl.js';
|
|
20
|
-
import { g as getShortUUID } from './index-wyPoxiTc.js';
|
|
21
|
-
import 'socket.io-client';
|
|
22
|
-
import 'isomorphic-git';
|
|
23
|
-
import '@oclif/core';
|
|
24
|
-
import { T as Table } from './Table-CvM6pccN.js';
|
|
25
|
-
import { T as Title } from './Title-BCQtayg6.js';
|
|
26
|
-
|
|
27
|
-
async function queryUserCredentials(params) {
|
|
28
|
-
try {
|
|
29
|
-
const headers = getAuthedHeaders();
|
|
30
|
-
const url = `${API_URL}/credentials`;
|
|
31
|
-
const response = await axios.get(url, { headers, params });
|
|
32
|
-
return {
|
|
33
|
-
...response.data,
|
|
34
|
-
data: castArrayObjectDates(response.data.data)
|
|
35
|
-
};
|
|
36
|
-
} catch (error) {
|
|
37
|
-
console.warn("queryUserCredentials Error", error);
|
|
38
|
-
throw error;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
function getUserCredentialSummary(credential) {
|
|
42
|
-
return {
|
|
43
|
-
id: getShortUUID(credential.id),
|
|
44
|
-
type: credential.type,
|
|
45
|
-
serial: credential.serialNumber,
|
|
46
|
-
isActive: credential.isActive,
|
|
47
|
-
createdAt: getShortDate(credential.createdAt)
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
const useUserCredentials = ({
|
|
51
|
-
platform,
|
|
52
|
-
type,
|
|
53
|
-
...pageAndSortParams
|
|
54
|
-
}) => {
|
|
55
|
-
const queryResult = useQuery({
|
|
56
|
-
queryKey: cacheKeys.userCredentials(pageAndSortParams),
|
|
57
|
-
queryFn: async () => queryUserCredentials(pageAndSortParams),
|
|
58
|
-
select: (data) => {
|
|
59
|
-
if (!(platform || type)) return data;
|
|
60
|
-
return {
|
|
61
|
-
...data,
|
|
62
|
-
data: data.data.filter((credential) => {
|
|
63
|
-
return (!platform || credential.platform === platform) && (!type || credential.type === type);
|
|
64
|
-
})
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
return queryResult;
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
const UserCredentialsTable = ({ credentialTypeName, queryProps, ...boxProps }) => {
|
|
72
|
-
const { isLoading, data } = useUserCredentials(queryProps);
|
|
73
|
-
const hasActive = data?.data.some((credential) => credential.isActive);
|
|
74
|
-
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginBottom: 1, ...boxProps, children: [
|
|
75
|
-
/* @__PURE__ */ jsx(Title, { children: `${credentialTypeName}s in your ShipThis account` }),
|
|
76
|
-
/* @__PURE__ */ jsx(Box, { marginLeft: 2, marginBottom: 1, flexDirection: "column", children: /* @__PURE__ */ jsx(Text, { children: hasActive ? `You have an active ${credentialTypeName} in your ShipThis account.` : `You DO NOT have an active ${credentialTypeName} which ShipThis can use.` }) }),
|
|
77
|
-
isLoading && /* @__PURE__ */ jsx(Spinner, { type: "dots" }),
|
|
78
|
-
data && data.data.length > 0 && /* @__PURE__ */ jsx(Table, { data: data.data.map(getUserCredentialSummary) })
|
|
79
|
-
] });
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
export { UserCredentialsTable as U, useUserCredentials as u };
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { Box, Text } from 'ink';
|
|
3
|
-
import Spinner from 'ink-spinner';
|
|
4
|
-
import 'crypto';
|
|
5
|
-
import 'fs';
|
|
6
|
-
import 'readline-sync';
|
|
7
|
-
import 'node:readline';
|
|
8
|
-
import 'node:path';
|
|
9
|
-
import 'node:url';
|
|
10
|
-
import 'react';
|
|
11
|
-
import axios from 'axios';
|
|
12
|
-
import { useQuery } from '@tanstack/react-query';
|
|
13
|
-
import { b as getShortDate, o as getAuthedHeaders, p as API_URL, M as castArrayObjectDates } from './index-C9734Cj2.js';
|
|
14
|
-
import 'crypto-js';
|
|
15
|
-
import 'uuid';
|
|
16
|
-
import 'luxon';
|
|
17
|
-
import 'fast-glob';
|
|
18
|
-
import 'yazl';
|
|
19
|
-
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-B_ekRewZ.js';
|
|
20
|
-
import { g as getShortUUID } from './index-DxHPjZav.js';
|
|
21
|
-
import 'socket.io-client';
|
|
22
|
-
import 'isomorphic-git';
|
|
23
|
-
import '@oclif/core';
|
|
24
|
-
import { T as Table } from './Table-CvM6pccN.js';
|
|
25
|
-
import { T as Title } from './Title-BCQtayg6.js';
|
|
26
|
-
|
|
27
|
-
async function queryUserCredentials(params) {
|
|
28
|
-
try {
|
|
29
|
-
const headers = getAuthedHeaders();
|
|
30
|
-
const url = `${API_URL}/credentials`;
|
|
31
|
-
const response = await axios.get(url, { headers, params });
|
|
32
|
-
return {
|
|
33
|
-
...response.data,
|
|
34
|
-
data: castArrayObjectDates(response.data.data)
|
|
35
|
-
};
|
|
36
|
-
} catch (error) {
|
|
37
|
-
console.warn("queryUserCredentials Error", error);
|
|
38
|
-
throw error;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
function getUserCredentialSummary(credential) {
|
|
42
|
-
return {
|
|
43
|
-
id: getShortUUID(credential.id),
|
|
44
|
-
type: credential.type,
|
|
45
|
-
serial: credential.serialNumber,
|
|
46
|
-
isActive: credential.isActive,
|
|
47
|
-
createdAt: getShortDate(credential.createdAt)
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
const useUserCredentials = ({
|
|
51
|
-
platform,
|
|
52
|
-
type,
|
|
53
|
-
...pageAndSortParams
|
|
54
|
-
}) => {
|
|
55
|
-
const queryResult = useQuery({
|
|
56
|
-
queryKey: cacheKeys.userCredentials(pageAndSortParams),
|
|
57
|
-
queryFn: async () => queryUserCredentials(pageAndSortParams),
|
|
58
|
-
select: (data) => {
|
|
59
|
-
if (!(platform || type)) return data;
|
|
60
|
-
return {
|
|
61
|
-
...data,
|
|
62
|
-
data: data.data.filter((credential) => {
|
|
63
|
-
return (!platform || credential.platform === platform) && (!type || credential.type === type);
|
|
64
|
-
})
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
return queryResult;
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
const UserCredentialsTable = ({ credentialTypeName, queryProps, ...boxProps }) => {
|
|
72
|
-
const { isLoading, data } = useUserCredentials(queryProps);
|
|
73
|
-
const hasActive = data?.data.some((credential) => credential.isActive);
|
|
74
|
-
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginBottom: 1, ...boxProps, children: [
|
|
75
|
-
/* @__PURE__ */ jsx(Title, { children: `${credentialTypeName}s in your ShipThis account` }),
|
|
76
|
-
/* @__PURE__ */ jsx(Box, { marginLeft: 2, marginBottom: 1, flexDirection: "column", children: /* @__PURE__ */ jsx(Text, { children: hasActive ? `You have an active ${credentialTypeName} in your ShipThis account.` : `You DO NOT have an active ${credentialTypeName} which ShipThis can use.` }) }),
|
|
77
|
-
isLoading && /* @__PURE__ */ jsx(Spinner, { type: "dots" }),
|
|
78
|
-
data && data.data.length > 0 && /* @__PURE__ */ jsx(Table, { data: data.data.map(getUserCredentialSummary) })
|
|
79
|
-
] });
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
export { UserCredentialsTable as U, useUserCredentials as u };
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { Box, Text } from 'ink';
|
|
3
|
-
import Spinner from 'ink-spinner';
|
|
4
|
-
import 'crypto';
|
|
5
|
-
import 'fs';
|
|
6
|
-
import 'readline-sync';
|
|
7
|
-
import 'node:readline';
|
|
8
|
-
import 'node:path';
|
|
9
|
-
import 'node:url';
|
|
10
|
-
import 'react';
|
|
11
|
-
import axios from 'axios';
|
|
12
|
-
import { useQuery } from '@tanstack/react-query';
|
|
13
|
-
import { b as getShortDate, p as getAuthedHeaders, q as API_URL, K as castArrayObjectDates } from './index-Bv3x8c78.js';
|
|
14
|
-
import 'crypto-js';
|
|
15
|
-
import 'uuid';
|
|
16
|
-
import 'luxon';
|
|
17
|
-
import 'fast-glob';
|
|
18
|
-
import 'yazl';
|
|
19
|
-
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-BDc7XpKE.js';
|
|
20
|
-
import { g as getShortUUID } from './index-BQnkBr1Q.js';
|
|
21
|
-
import 'socket.io-client';
|
|
22
|
-
import 'isomorphic-git';
|
|
23
|
-
import '@oclif/core';
|
|
24
|
-
import { T as Table } from './Table-CvM6pccN.js';
|
|
25
|
-
import { T as Title } from './Title-BCQtayg6.js';
|
|
26
|
-
|
|
27
|
-
async function queryUserCredentials(params) {
|
|
28
|
-
try {
|
|
29
|
-
const headers = getAuthedHeaders();
|
|
30
|
-
const url = `${API_URL}/credentials`;
|
|
31
|
-
const response = await axios.get(url, { headers, params });
|
|
32
|
-
return {
|
|
33
|
-
...response.data,
|
|
34
|
-
data: castArrayObjectDates(response.data.data)
|
|
35
|
-
};
|
|
36
|
-
} catch (error) {
|
|
37
|
-
console.warn("queryUserCredentials Error", error);
|
|
38
|
-
throw error;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
function getUserCredentialSummary(credential) {
|
|
42
|
-
return {
|
|
43
|
-
id: getShortUUID(credential.id),
|
|
44
|
-
type: credential.type,
|
|
45
|
-
serial: credential.serialNumber,
|
|
46
|
-
isActive: credential.isActive,
|
|
47
|
-
createdAt: getShortDate(credential.createdAt)
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
const useUserCredentials = ({
|
|
51
|
-
platform,
|
|
52
|
-
type,
|
|
53
|
-
...pageAndSortParams
|
|
54
|
-
}) => {
|
|
55
|
-
const queryResult = useQuery({
|
|
56
|
-
queryKey: cacheKeys.userCredentials(pageAndSortParams),
|
|
57
|
-
queryFn: async () => queryUserCredentials(pageAndSortParams),
|
|
58
|
-
select: (data) => {
|
|
59
|
-
if (!(platform || type)) return data;
|
|
60
|
-
return {
|
|
61
|
-
...data,
|
|
62
|
-
data: data.data.filter((credential) => {
|
|
63
|
-
return (!platform || credential.platform === platform) && (!type || credential.type === type);
|
|
64
|
-
})
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
return queryResult;
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
const UserCredentialsTable = ({ credentialTypeName, queryProps, ...boxProps }) => {
|
|
72
|
-
const { isLoading, data } = useUserCredentials(queryProps);
|
|
73
|
-
const hasActive = data?.data.some((credential) => credential.isActive);
|
|
74
|
-
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginBottom: 1, ...boxProps, children: [
|
|
75
|
-
/* @__PURE__ */ jsx(Title, { children: `${credentialTypeName}s in your ShipThis account` }),
|
|
76
|
-
/* @__PURE__ */ jsx(Box, { marginLeft: 2, marginBottom: 1, flexDirection: "column", children: /* @__PURE__ */ jsx(Text, { children: hasActive ? `You have an active ${credentialTypeName} in your ShipThis account.` : `You DO NOT have an active ${credentialTypeName} which ShipThis can use.` }) }),
|
|
77
|
-
isLoading && /* @__PURE__ */ jsx(Spinner, { type: "dots" }),
|
|
78
|
-
data && data.data.length > 0 && /* @__PURE__ */ jsx(Table, { data: data.data.map(getUserCredentialSummary) })
|
|
79
|
-
] });
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
export { UserCredentialsTable as U, useUserCredentials as u };
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import { Box, Text } from 'ink';
|
|
3
|
-
import Spinner from 'ink-spinner';
|
|
4
|
-
import 'crypto';
|
|
5
|
-
import 'fs';
|
|
6
|
-
import 'readline-sync';
|
|
7
|
-
import 'node:readline';
|
|
8
|
-
import 'node:path';
|
|
9
|
-
import 'node:url';
|
|
10
|
-
import 'react';
|
|
11
|
-
import axios from 'axios';
|
|
12
|
-
import { useQuery } from '@tanstack/react-query';
|
|
13
|
-
import { b as getShortDate, p as getAuthedHeaders, q as API_URL, J as castArrayObjectDates } from './index-BQRxiyqn.js';
|
|
14
|
-
import 'crypto-js';
|
|
15
|
-
import 'uuid';
|
|
16
|
-
import 'luxon';
|
|
17
|
-
import 'fast-glob';
|
|
18
|
-
import 'yazl';
|
|
19
|
-
import { c as cacheKeys } from './useAndroidServiceAccountTestResult-D_30xIJA.js';
|
|
20
|
-
import { g as getShortUUID } from './index-B6V7vGOj.js';
|
|
21
|
-
import 'socket.io-client';
|
|
22
|
-
import 'isomorphic-git';
|
|
23
|
-
import '@oclif/core';
|
|
24
|
-
import { T as Table } from './Table-CvM6pccN.js';
|
|
25
|
-
import { T as Title } from './Title-BCQtayg6.js';
|
|
26
|
-
|
|
27
|
-
async function queryUserCredentials(params) {
|
|
28
|
-
try {
|
|
29
|
-
const headers = getAuthedHeaders();
|
|
30
|
-
const url = `${API_URL}/credentials`;
|
|
31
|
-
const response = await axios.get(url, { headers, params });
|
|
32
|
-
return {
|
|
33
|
-
...response.data,
|
|
34
|
-
data: castArrayObjectDates(response.data.data)
|
|
35
|
-
};
|
|
36
|
-
} catch (error) {
|
|
37
|
-
console.warn("queryUserCredentials Error", error);
|
|
38
|
-
throw error;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
function getUserCredentialSummary(credential) {
|
|
42
|
-
return {
|
|
43
|
-
id: getShortUUID(credential.id),
|
|
44
|
-
type: credential.type,
|
|
45
|
-
serial: credential.serialNumber,
|
|
46
|
-
isActive: credential.isActive,
|
|
47
|
-
createdAt: getShortDate(credential.createdAt)
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
const useUserCredentials = ({
|
|
51
|
-
platform,
|
|
52
|
-
type,
|
|
53
|
-
...pageAndSortParams
|
|
54
|
-
}) => {
|
|
55
|
-
const queryResult = useQuery({
|
|
56
|
-
queryKey: cacheKeys.userCredentials(pageAndSortParams),
|
|
57
|
-
queryFn: async () => queryUserCredentials(pageAndSortParams),
|
|
58
|
-
select: (data) => {
|
|
59
|
-
if (!(platform || type)) return data;
|
|
60
|
-
return {
|
|
61
|
-
...data,
|
|
62
|
-
data: data.data.filter((credential) => {
|
|
63
|
-
return (!platform || credential.platform === platform) && (!type || credential.type === type);
|
|
64
|
-
})
|
|
65
|
-
};
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
return queryResult;
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
const UserCredentialsTable = ({ credentialTypeName, queryProps, ...boxProps }) => {
|
|
72
|
-
const { isLoading, data } = useUserCredentials(queryProps);
|
|
73
|
-
const hasActive = data?.data.some((credential) => credential.isActive);
|
|
74
|
-
return /* @__PURE__ */ jsxs(Box, { flexDirection: "column", marginBottom: 1, ...boxProps, children: [
|
|
75
|
-
/* @__PURE__ */ jsx(Title, { children: `${credentialTypeName}s in your ShipThis account` }),
|
|
76
|
-
/* @__PURE__ */ jsx(Box, { marginLeft: 2, marginBottom: 1, flexDirection: "column", children: /* @__PURE__ */ jsx(Text, { children: hasActive ? `You have an active ${credentialTypeName} in your ShipThis account.` : `You DO NOT have an active ${credentialTypeName} which ShipThis can use.` }) }),
|
|
77
|
-
isLoading && /* @__PURE__ */ jsx(Spinner, { type: "dots" }),
|
|
78
|
-
data && data.data.length > 0 && /* @__PURE__ */ jsx(Table, { data: data.data.map(getUserCredentialSummary) })
|
|
79
|
-
] });
|
|
80
|
-
};
|
|
81
|
-
|
|
82
|
-
export { UserCredentialsTable as U, useUserCredentials as u };
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { c as BaseGameCommand, R as getGodotAndroidPackageName, S as getGoogleStatus } from './index-BQRxiyqn.js';
|
|
2
|
-
import { b as generatePackageName, a as getInput } from './index-B6V7vGOj.js';
|
|
3
|
-
|
|
4
|
-
class BaseGameAndroidCommand extends BaseGameCommand {
|
|
5
|
-
async init() {
|
|
6
|
-
await super.init();
|
|
7
|
-
await this.ensureWeHaveAndroidPackageName();
|
|
8
|
-
}
|
|
9
|
-
// Prompts the user for the Android package name
|
|
10
|
-
async getAndroidPackageName(gameId) {
|
|
11
|
-
const game = await this.getGame();
|
|
12
|
-
const generated = generatePackageName(game.name);
|
|
13
|
-
const suggested = game.details?.iosBundleId || getGodotAndroidPackageName() || generated || "com.example.game";
|
|
14
|
-
const question = `Please enter the Android Package Name, or press enter to use ${suggested}: `;
|
|
15
|
-
const entered = await getInput(question);
|
|
16
|
-
return entered || suggested;
|
|
17
|
-
}
|
|
18
|
-
// Forces us to have the androidPackageName in the game details
|
|
19
|
-
async ensureWeHaveAndroidPackageName() {
|
|
20
|
-
const game = await this.getGame();
|
|
21
|
-
if (!game.details?.androidPackageName) {
|
|
22
|
-
const androidPackageName = await this.getAndroidPackageName(game.id);
|
|
23
|
-
await this.updateGame({ details: { ...game.details, androidPackageName } });
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
async checkGoogleAuth(waitForAuth = false) {
|
|
27
|
-
let status = await getGoogleStatus();
|
|
28
|
-
if (status.isAuthenticated) return;
|
|
29
|
-
if (!waitForAuth)
|
|
30
|
-
this.error("You must connect to Google first. Run `shipthis game android apiKey connect`", { exit: 1 });
|
|
31
|
-
this.log("Waiting for Google authentication...");
|
|
32
|
-
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
33
|
-
for (let i = 0; i < 600; i++) {
|
|
34
|
-
process.stdout.write(".");
|
|
35
|
-
await sleep(1e3 * 10);
|
|
36
|
-
status = await getGoogleStatus();
|
|
37
|
-
if (status.isAuthenticated) return;
|
|
38
|
-
}
|
|
39
|
-
this.error("Google authentication failed. Please try again.", { exit: 1 });
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export { BaseGameAndroidCommand as B };
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { c as BaseGameCommand, O as getGodotAndroidPackageName, Q as getGoogleStatus } from './index-C9734Cj2.js';
|
|
2
|
-
import { b as generatePackageName, a as getInput } from './index-DxHPjZav.js';
|
|
3
|
-
|
|
4
|
-
class BaseGameAndroidCommand extends BaseGameCommand {
|
|
5
|
-
async init() {
|
|
6
|
-
await super.init();
|
|
7
|
-
await this.ensureWeHaveAndroidPackageName();
|
|
8
|
-
}
|
|
9
|
-
// Prompts the user for the Android package name
|
|
10
|
-
async getAndroidPackageName(gameId) {
|
|
11
|
-
const game = await this.getGame();
|
|
12
|
-
const generated = generatePackageName(game.name);
|
|
13
|
-
const suggested = game.details?.iosBundleId || getGodotAndroidPackageName() || generated || "com.example.game";
|
|
14
|
-
const question = `Please enter the Android Package Name, or press enter to use ${suggested}: `;
|
|
15
|
-
const entered = await getInput(question);
|
|
16
|
-
return entered || suggested;
|
|
17
|
-
}
|
|
18
|
-
// Forces us to have the androidPackageName in the game details
|
|
19
|
-
async ensureWeHaveAndroidPackageName() {
|
|
20
|
-
const game = await this.getGame();
|
|
21
|
-
if (!game.details?.androidPackageName) {
|
|
22
|
-
const androidPackageName = await this.getAndroidPackageName(game.id);
|
|
23
|
-
await this.updateGame({ details: { ...game.details, androidPackageName } });
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
async checkGoogleAuth(waitForAuth = false) {
|
|
27
|
-
let status = await getGoogleStatus();
|
|
28
|
-
if (status.isAuthenticated) return;
|
|
29
|
-
if (!waitForAuth)
|
|
30
|
-
this.error("You must connect to Google first. Run `shipthis game android apiKey connect`", { exit: 1 });
|
|
31
|
-
this.log("Waiting for Google authentication...");
|
|
32
|
-
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
33
|
-
for (let i = 0; i < 600; i++) {
|
|
34
|
-
process.stdout.write(".");
|
|
35
|
-
await sleep(1e3 * 10);
|
|
36
|
-
status = await getGoogleStatus();
|
|
37
|
-
if (status.isAuthenticated) return;
|
|
38
|
-
}
|
|
39
|
-
this.error("Google authentication failed. Please try again.", { exit: 1 });
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export { BaseGameAndroidCommand as B };
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { c as BaseGameCommand, O as getGodotAndroidPackageName, Q as getGoogleStatus } from './index-Bv3x8c78.js';
|
|
2
|
-
import { b as generatePackageName, a as getInput } from './index-BQnkBr1Q.js';
|
|
3
|
-
|
|
4
|
-
class BaseGameAndroidCommand extends BaseGameCommand {
|
|
5
|
-
async init() {
|
|
6
|
-
await super.init();
|
|
7
|
-
await this.ensureWeHaveAndroidPackageName();
|
|
8
|
-
}
|
|
9
|
-
// Prompts the user for the Android package name
|
|
10
|
-
async getAndroidPackageName(gameId) {
|
|
11
|
-
const game = await this.getGame();
|
|
12
|
-
const generated = generatePackageName(game.name);
|
|
13
|
-
const suggested = game.details?.iosBundleId || getGodotAndroidPackageName() || generated || "com.example.game";
|
|
14
|
-
const question = `Please enter the Android Package Name, or press enter to use ${suggested}: `;
|
|
15
|
-
const entered = await getInput(question);
|
|
16
|
-
return entered || suggested;
|
|
17
|
-
}
|
|
18
|
-
// Forces us to have the androidPackageName in the game details
|
|
19
|
-
async ensureWeHaveAndroidPackageName() {
|
|
20
|
-
const game = await this.getGame();
|
|
21
|
-
if (!game.details?.androidPackageName) {
|
|
22
|
-
const androidPackageName = await this.getAndroidPackageName(game.id);
|
|
23
|
-
await this.updateGame({ details: { ...game.details, androidPackageName } });
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
async checkGoogleAuth(waitForAuth = false) {
|
|
27
|
-
let status = await getGoogleStatus();
|
|
28
|
-
if (status.isAuthenticated) return;
|
|
29
|
-
if (!waitForAuth)
|
|
30
|
-
this.error("You must connect to Google first. Run `shipthis game android apiKey connect`", { exit: 1 });
|
|
31
|
-
this.log("Waiting for Google authentication...");
|
|
32
|
-
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
33
|
-
for (let i = 0; i < 600; i++) {
|
|
34
|
-
process.stdout.write(".");
|
|
35
|
-
await sleep(1e3 * 10);
|
|
36
|
-
status = await getGoogleStatus();
|
|
37
|
-
if (status.isAuthenticated) return;
|
|
38
|
-
}
|
|
39
|
-
this.error("Google authentication failed. Please try again.", { exit: 1 });
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export { BaseGameAndroidCommand as B };
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { c as BaseGameCommand, O as getGodotAndroidPackageName, Q as getGoogleStatus } from './index-DdABTtYO.js';
|
|
2
|
-
import { b as generatePackageName, a as getInput } from './index-wyPoxiTc.js';
|
|
3
|
-
|
|
4
|
-
class BaseGameAndroidCommand extends BaseGameCommand {
|
|
5
|
-
async init() {
|
|
6
|
-
await super.init();
|
|
7
|
-
await this.ensureWeHaveAndroidPackageName();
|
|
8
|
-
}
|
|
9
|
-
// Prompts the user for the Android package name
|
|
10
|
-
async getAndroidPackageName(gameId) {
|
|
11
|
-
const game = await this.getGame();
|
|
12
|
-
const generated = generatePackageName(game.name);
|
|
13
|
-
const suggested = game.details?.iosBundleId || getGodotAndroidPackageName() || generated || "com.example.game";
|
|
14
|
-
const question = `Please enter the Android Package Name, or press enter to use ${suggested}: `;
|
|
15
|
-
const entered = await getInput(question);
|
|
16
|
-
return entered || suggested;
|
|
17
|
-
}
|
|
18
|
-
// Forces us to have the androidPackageName in the game details
|
|
19
|
-
async ensureWeHaveAndroidPackageName() {
|
|
20
|
-
const game = await this.getGame();
|
|
21
|
-
if (!game.details?.androidPackageName) {
|
|
22
|
-
const androidPackageName = await this.getAndroidPackageName(game.id);
|
|
23
|
-
await this.updateGame({ details: { ...game.details, androidPackageName } });
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
async checkGoogleAuth(waitForAuth = false) {
|
|
27
|
-
let status = await getGoogleStatus();
|
|
28
|
-
if (status.isAuthenticated) return;
|
|
29
|
-
if (!waitForAuth)
|
|
30
|
-
this.error("You must connect to Google first. Run `shipthis game android apiKey connect`", { exit: 1 });
|
|
31
|
-
this.log("Waiting for Google authentication...");
|
|
32
|
-
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
33
|
-
for (let i = 0; i < 600; i++) {
|
|
34
|
-
process.stdout.write(".");
|
|
35
|
-
await sleep(1e3 * 10);
|
|
36
|
-
status = await getGoogleStatus();
|
|
37
|
-
if (status.isAuthenticated) return;
|
|
38
|
-
}
|
|
39
|
-
this.error("Google authentication failed. Please try again.", { exit: 1 });
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export { BaseGameAndroidCommand as B };
|