@solana-mobile/dapp-store-cli 0.1.6 → 0.1.8
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 +1 -5
- package/lib/esm/commands/create/app.js +3 -2
- package/lib/esm/commands/create/app.js.map +1 -1
- package/lib/esm/commands/publish/remove.js +3 -2
- package/lib/esm/commands/publish/remove.js.map +1 -1
- package/lib/esm/commands/publish/submit.js +3 -2
- package/lib/esm/commands/publish/submit.js.map +1 -1
- package/lib/esm/commands/publish/support.js +3 -2
- package/lib/esm/commands/publish/support.js.map +1 -1
- package/lib/esm/commands/publish/update.js +3 -2
- package/lib/esm/commands/publish/update.js.map +1 -1
- package/lib/esm/config/index.js +1 -1
- package/lib/esm/config/index.js.map +1 -1
- package/lib/esm/config/schema.json +0 -4
- package/lib/esm/index.js +92 -79
- package/lib/esm/index.js.map +1 -1
- package/lib/esm/package.json +57 -0
- package/lib/esm/utils.js +34 -6
- package/lib/esm/utils.js.map +1 -1
- package/lib/types/commands/create/app.d.ts.map +1 -1
- package/lib/types/commands/publish/remove.d.ts +2 -1
- package/lib/types/commands/publish/remove.d.ts.map +1 -1
- package/lib/types/commands/publish/submit.d.ts +2 -1
- package/lib/types/commands/publish/submit.d.ts.map +1 -1
- package/lib/types/commands/publish/support.d.ts +2 -1
- package/lib/types/commands/publish/support.d.ts.map +1 -1
- package/lib/types/commands/publish/update.d.ts +2 -1
- package/lib/types/commands/publish/update.d.ts.map +1 -1
- package/lib/types/utils.d.ts +3 -1
- package/lib/types/utils.d.ts.map +1 -1
- package/package.json +11 -3
- package/src/commands/create/app.ts +3 -2
- package/src/commands/publish/remove.ts +4 -0
- package/src/commands/publish/submit.ts +4 -0
- package/src/commands/publish/support.ts +4 -0
- package/src/commands/publish/update.ts +4 -0
- package/src/config/index.ts +1 -1
- package/src/config/schema.json +0 -4
- package/src/index.ts +124 -91
- package/src/utils.ts +41 -7
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@solana-mobile/dapp-store-cli",
|
|
3
|
+
"version": "0.1.8",
|
|
4
|
+
"license": "Apache-2.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"sideEffects": false,
|
|
7
|
+
"main": "./lib/cjs/index.js",
|
|
8
|
+
"module": "./lib/esm/index.js",
|
|
9
|
+
"types": "./lib/types/index.d.ts",
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": ">=18"
|
|
12
|
+
},
|
|
13
|
+
"exports": {
|
|
14
|
+
"import": "./lib/esm/index.js",
|
|
15
|
+
"require": "./lib/cjs/index.js",
|
|
16
|
+
"types": "./lib/types/index.d.ts"
|
|
17
|
+
},
|
|
18
|
+
"bin": {
|
|
19
|
+
"dapp-store": "./bin/dapp-store.js"
|
|
20
|
+
},
|
|
21
|
+
"files": [
|
|
22
|
+
"lib",
|
|
23
|
+
"src",
|
|
24
|
+
"LICENSE"
|
|
25
|
+
],
|
|
26
|
+
"publishConfig": {
|
|
27
|
+
"access": "public"
|
|
28
|
+
},
|
|
29
|
+
"scripts": {
|
|
30
|
+
"clean": "shx mkdir -p lib && shx rm -rf lib",
|
|
31
|
+
"prebuild": "pnpm run clean"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@metaplex-foundation/js": "0.17.11",
|
|
35
|
+
"@types/commander": "^2.12.2",
|
|
36
|
+
"@types/debug": "^4.1.7",
|
|
37
|
+
"@types/js-yaml": "^4.0.5",
|
|
38
|
+
"@types/terminal-link": "^1.2.0",
|
|
39
|
+
"@types/update-notifier": "^6.0.1",
|
|
40
|
+
"shx": "^0.3.4"
|
|
41
|
+
},
|
|
42
|
+
"dependencies": {
|
|
43
|
+
"@solana-mobile/dapp-store-publishing-tools": "workspace:0.1.8",
|
|
44
|
+
"@solana/web3.js": "1.68.0",
|
|
45
|
+
"ajv": "^8.11.0",
|
|
46
|
+
"boxen": "^7.0.1",
|
|
47
|
+
"commander": "^9.4.1",
|
|
48
|
+
"debug": "^4.3.4",
|
|
49
|
+
"dotenv": "^16.0.3",
|
|
50
|
+
"esm": "^3.2.25",
|
|
51
|
+
"image-size": "^1.0.2",
|
|
52
|
+
"js-yaml": "^4.1.0",
|
|
53
|
+
"terminal-link": "^3.0.0",
|
|
54
|
+
"tweetnacl": "1.0.3",
|
|
55
|
+
"update-notifier": "^6.0.2"
|
|
56
|
+
}
|
|
57
|
+
}
|
package/lib/esm/utils.js
CHANGED
|
@@ -8,10 +8,20 @@ import { exec } from "child_process";
|
|
|
8
8
|
import * as path from "path";
|
|
9
9
|
import { BundlrStorageDriver, keypairIdentity, Metaplex, toMetaplexFile } from "@metaplex-foundation/js";
|
|
10
10
|
import { imageSize } from "image-size";
|
|
11
|
+
import updateNotifier from "update-notifier";
|
|
12
|
+
import cliPackage from "./package.json" assert { type: "json" };
|
|
13
|
+
import boxen from "boxen";
|
|
11
14
|
import { CachedStorageDriver } from "./upload/CachedStorageDriver.js";
|
|
12
15
|
const runImgSize = util.promisify(imageSize);
|
|
13
16
|
const runExec = util.promisify(exec);
|
|
14
17
|
export const debug = debugModule("CLI");
|
|
18
|
+
export const checkForSelfUpdate = async () => {
|
|
19
|
+
const notifier = updateNotifier({ pkg: cliPackage });
|
|
20
|
+
const updateInfo = await notifier.fetchInfo();
|
|
21
|
+
if (updateInfo.current != updateInfo.latest) {
|
|
22
|
+
throw new Error("Please update to the latest version of the dApp Store CLI before proceeding.");
|
|
23
|
+
}
|
|
24
|
+
};
|
|
15
25
|
export const parseKeypair = (pathToKeypairFile) => {
|
|
16
26
|
try {
|
|
17
27
|
const keypairFile = fs.readFileSync(pathToKeypairFile, "utf-8");
|
|
@@ -34,7 +44,6 @@ const AaptPrefixes = {
|
|
|
34
44
|
export const getConfigFile = async (buildToolsDir = null) => {
|
|
35
45
|
const configFilePath = `${process.cwd()}/config.yaml`;
|
|
36
46
|
const config = await getConfig(configFilePath);
|
|
37
|
-
console.info(`Pulling details from ${configFilePath}`);
|
|
38
47
|
if (buildToolsDir && fs.lstatSync(buildToolsDir).isDirectory()) {
|
|
39
48
|
// We validate that the config is going to have at least one installable asset
|
|
40
49
|
const apkEntry = config.release.files.find((asset) => asset.purpose === "install");
|
|
@@ -83,10 +92,29 @@ const checkImageExtension = (uri) => {
|
|
|
83
92
|
fileExt == ".jpeg" ||
|
|
84
93
|
fileExt == ".webp");
|
|
85
94
|
};
|
|
86
|
-
export const
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
95
|
+
export const generateNetworkSuffix = (rpcUrl) => {
|
|
96
|
+
let suffix = "";
|
|
97
|
+
if (rpcUrl.indexOf("devnet") != -1) {
|
|
98
|
+
suffix = "?cluster=devnet";
|
|
99
|
+
}
|
|
100
|
+
else if (rpcUrl.indexOf("testnet") != -1) {
|
|
101
|
+
suffix = "?cluster=testnet";
|
|
102
|
+
}
|
|
103
|
+
else if (rpcUrl.indexOf("mainnet") != -1) {
|
|
104
|
+
suffix = "?cluster=mainnet";
|
|
105
|
+
}
|
|
106
|
+
return suffix;
|
|
107
|
+
};
|
|
108
|
+
export const showMessage = (titleMessage = "", contentMessage = "", isError = false) => {
|
|
109
|
+
console.log(boxen(contentMessage, {
|
|
110
|
+
title: titleMessage,
|
|
111
|
+
padding: 1,
|
|
112
|
+
margin: 1,
|
|
113
|
+
borderStyle: 'single',
|
|
114
|
+
borderColor: isError ? "redBright" : "cyan",
|
|
115
|
+
textAlignment: "left",
|
|
116
|
+
titleAlignment: "center"
|
|
117
|
+
}));
|
|
90
118
|
};
|
|
91
119
|
const checkIconDimensions = async (iconPath) => {
|
|
92
120
|
const size = await runImgSize(iconPath);
|
|
@@ -107,7 +135,7 @@ const getAndroidDetails = async (aaptDir, apkPath) => {
|
|
|
107
135
|
let localeArray = Array.from(locales?.values() ?? []);
|
|
108
136
|
if (localeArray.length == 2) {
|
|
109
137
|
const localesSrc = localeArray[1];
|
|
110
|
-
localeArray = localesSrc.split("' '").slice(1);
|
|
138
|
+
localeArray = ["en-US"].concat(localesSrc.split("' '").slice(1));
|
|
111
139
|
}
|
|
112
140
|
return {
|
|
113
141
|
android_package: appPackage?.[1] ?? "",
|
package/lib/esm/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AAGpB,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE1C,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,WAAW,MAAM,OAAO,CAAC;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AACrC,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzG,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AAGpB,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE1C,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAC9C,OAAO,WAAW,MAAM,OAAO,CAAC;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AACrC,OAAO,KAAK,IAAI,MAAM,MAAM,CAAC;AAC7B,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzG,OAAO,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AC7C,CAAC;QACJ,CAAC,CAAC,IAAI,mBAAmB,CAAC,QAAQ,CAAC,CAAC;IAEtC,QAAQ,CAAC,OAAO,EAAE,CAAC,SAAS,CAC1B,IAAI,mBAAmB,CAAC,mBAAmB,EAAE;QAC3C,iBAAiB,EAAE,QAAQ;YACzB,CAAC,CAAC,+BAA+B;YACjC,CAAC,CAAC,wBAAwB;KAC7B,CAAC,CACH,CAAC;IACF,OAAO,QAAQ,CAAC;AAClB,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../../src/commands/create/app.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,OAAO,EAGR,MAAM,iBAAiB,CAAC;AAgDzB,aAAK,qBAAqB,GAAG;IAC3B,oBAAoB,EAAE,MAAM,CAAC;IAC7B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,eAAO,MAAM,gBAAgB,mDAK1B,qBAAqB;;
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../../src/commands/create/app.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,OAAO,EAGR,MAAM,iBAAiB,CAAC;AAgDzB,aAAK,qBAAqB,GAAG;IAC3B,oBAAoB,EAAE,MAAM,CAAC;IAC7B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,eAAO,MAAM,gBAAgB,mDAK1B,qBAAqB;;EAqBvB,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Keypair } from "@solana/web3.js";
|
|
2
2
|
declare type PublishRemoveCommandInput = {
|
|
3
|
+
appMintAddress: string;
|
|
3
4
|
releaseMintAddress: string;
|
|
4
5
|
signer: Keypair;
|
|
5
6
|
url: string;
|
|
@@ -7,6 +8,6 @@ declare type PublishRemoveCommandInput = {
|
|
|
7
8
|
requestorIsAuthorized: boolean;
|
|
8
9
|
critical: boolean;
|
|
9
10
|
};
|
|
10
|
-
export declare const publishRemoveCommand: ({ releaseMintAddress, signer, url, dryRun, requestorIsAuthorized, critical, }: PublishRemoveCommandInput) => Promise<void>;
|
|
11
|
+
export declare const publishRemoveCommand: ({ appMintAddress, releaseMintAddress, signer, url, dryRun, requestorIsAuthorized, critical, }: PublishRemoveCommandInput) => Promise<void>;
|
|
11
12
|
export {};
|
|
12
13
|
//# sourceMappingURL=remove.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remove.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/remove.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,oBAAoB,
|
|
1
|
+
{"version":3,"file":"remove.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/remove.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,oBAAoB,kGAQ9B,yBAAyB,kBA4B3B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Keypair } from "@solana/web3.js";
|
|
2
2
|
declare type PublishSubmitCommandInput = {
|
|
3
|
+
appMintAddress: string;
|
|
3
4
|
releaseMintAddress: string;
|
|
4
5
|
signer: Keypair;
|
|
5
6
|
url: string;
|
|
@@ -7,6 +8,6 @@ declare type PublishSubmitCommandInput = {
|
|
|
7
8
|
compliesWithSolanaDappStorePolicies: boolean;
|
|
8
9
|
requestorIsAuthorized: boolean;
|
|
9
10
|
};
|
|
10
|
-
export declare const publishSubmitCommand: ({ releaseMintAddress, signer, url, dryRun, compliesWithSolanaDappStorePolicies, requestorIsAuthorized, }: PublishSubmitCommandInput) => Promise<void>;
|
|
11
|
+
export declare const publishSubmitCommand: ({ appMintAddress, releaseMintAddress, signer, url, dryRun, compliesWithSolanaDappStorePolicies, requestorIsAuthorized, }: PublishSubmitCommandInput) => Promise<void>;
|
|
11
12
|
export {};
|
|
12
13
|
//# sourceMappingURL=submit.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"submit.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/submit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,mCAAmC,EAAE,OAAO,CAAC;IAC7C,qBAAqB,EAAE,OAAO,CAAC;CAChC,CAAC;AAEF,eAAO,MAAM,oBAAoB,
|
|
1
|
+
{"version":3,"file":"submit.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/submit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,mCAAmC,EAAE,OAAO,CAAC;IAC7C,qBAAqB,EAAE,OAAO,CAAC;CAChC,CAAC;AAEF,eAAO,MAAM,oBAAoB,6HAQ9B,yBAAyB,kBAmC3B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Keypair } from "@solana/web3.js";
|
|
2
2
|
declare type PublishSupportCommandInput = {
|
|
3
|
+
appMintAddress: string;
|
|
3
4
|
releaseMintAddress: string;
|
|
4
5
|
signer: Keypair;
|
|
5
6
|
url: string;
|
|
@@ -7,6 +8,6 @@ declare type PublishSupportCommandInput = {
|
|
|
7
8
|
requestorIsAuthorized: boolean;
|
|
8
9
|
requestDetails: string;
|
|
9
10
|
};
|
|
10
|
-
export declare const publishSupportCommand: ({ releaseMintAddress, signer, url, dryRun, requestorIsAuthorized, requestDetails, }: PublishSupportCommandInput) => Promise<void>;
|
|
11
|
+
export declare const publishSupportCommand: ({ appMintAddress, releaseMintAddress, signer, url, dryRun, requestorIsAuthorized, requestDetails, }: PublishSupportCommandInput) => Promise<void>;
|
|
11
12
|
export {};
|
|
12
13
|
//# sourceMappingURL=support.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"support.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/support.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,0BAA0B,GAAG;IAChC,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,cAAc,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"support.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/support.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,0BAA0B,GAAG;IAChC,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,qBAAqB,EAAE,OAAO,CAAC;IAC/B,cAAc,EAAE,MAAM,CAAC;CACxB,CAAC;AAEF,eAAO,MAAM,qBAAqB,wGAQ/B,0BAA0B,kBA4B5B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Keypair } from "@solana/web3.js";
|
|
2
2
|
declare type PublishUpdateCommandInput = {
|
|
3
|
+
appMintAddress: string;
|
|
3
4
|
releaseMintAddress: string;
|
|
4
5
|
signer: Keypair;
|
|
5
6
|
url: string;
|
|
@@ -8,6 +9,6 @@ declare type PublishUpdateCommandInput = {
|
|
|
8
9
|
requestorIsAuthorized: boolean;
|
|
9
10
|
critical: boolean;
|
|
10
11
|
};
|
|
11
|
-
export declare const publishUpdateCommand: ({ releaseMintAddress, signer, url, dryRun, compliesWithSolanaDappStorePolicies, requestorIsAuthorized, critical, }: PublishUpdateCommandInput) => Promise<void>;
|
|
12
|
+
export declare const publishUpdateCommand: ({ appMintAddress, releaseMintAddress, signer, url, dryRun, compliesWithSolanaDappStorePolicies, requestorIsAuthorized, critical, }: PublishUpdateCommandInput) => Promise<void>;
|
|
12
13
|
export {};
|
|
13
14
|
//# sourceMappingURL=update.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/update.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,mCAAmC,EAAE,OAAO,CAAC;IAC7C,qBAAqB,EAAE,OAAO,CAAC;IAC/B,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,oBAAoB,
|
|
1
|
+
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../../../src/commands/publish/update.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAMtD,aAAK,yBAAyB,GAAG;IAC/B,cAAc,EAAE,MAAM,CAAC;IACvB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,MAAM,EAAE,OAAO,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,OAAO,CAAC;IAChB,mCAAmC,EAAE,OAAO,CAAC;IAC7C,qBAAqB,EAAE,OAAO,CAAC;IAC/B,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,eAAO,MAAM,oBAAoB,uIAS9B,yBAAyB,kBAoC3B,CAAC"}
|
package/lib/types/utils.d.ts
CHANGED
|
@@ -5,9 +5,11 @@ import type { CLIConfig } from "./config/index.js";
|
|
|
5
5
|
import debugModule from "debug";
|
|
6
6
|
import { Metaplex } from "@metaplex-foundation/js";
|
|
7
7
|
export declare const debug: debugModule.Debugger;
|
|
8
|
+
export declare const checkForSelfUpdate: () => Promise<void>;
|
|
8
9
|
export declare const parseKeypair: (pathToKeypairFile: string) => Keypair | undefined;
|
|
9
10
|
export declare const getConfigFile: (buildToolsDir?: string | null) => Promise<CLIConfig>;
|
|
10
|
-
export declare const
|
|
11
|
+
export declare const generateNetworkSuffix: (rpcUrl: string) => string;
|
|
12
|
+
export declare const showMessage: (titleMessage?: string, contentMessage?: string, isError?: boolean) => void;
|
|
11
13
|
declare type SaveToConfigArgs = {
|
|
12
14
|
publisher?: Pick<Publisher, "address">;
|
|
13
15
|
app?: Pick<App, "address">;
|
package/lib/types/utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAkB,GAAG,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,4CAA4C,CAAC;AAC1G,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAC1C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,WAAW,MAAM,OAAO,CAAC;AAKhC,OAAO,EAAwC,QAAQ,EAAkB,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAkB,GAAG,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,4CAA4C,CAAC;AAC1G,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAC1C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,OAAO,WAAW,MAAM,OAAO,CAAC;AAKhC,OAAO,EAAwC,QAAQ,EAAkB,MAAM,yBAAyB,CAAC;AAWzG,eAAO,MAAM,KAAK,sBAAqB,CAAC;AAExC,eAAO,MAAM,kBAAkB,qBAO9B,CAAC;AAEF,eAAO,MAAM,YAAY,sBAAuB,MAAM,wBASrD,CAAC;AAaF,eAAO,MAAM,aAAa,mBACT,MAAM,GAAG,IAAI,KAC3B,QAAQ,SAAS,CAiEnB,CAAC;AAYF,eAAO,MAAM,qBAAqB,WAAY,MAAM,KAAG,MAYtD,CAAC;AAEF,eAAO,MAAM,WAAW,6EAcvB,CAAC;AAsDF,aAAK,gBAAgB,GAAG;IACtB,SAAS,CAAC,EAAE,IAAI,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;IACvC,GAAG,CAAC,EAAE,IAAI,CAAC,GAAG,EAAE,SAAS,CAAC,CAAC;IAC3B,OAAO,CAAC,EAAE,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,YAAY,iCAItB,gBAAgB,kBAyBlB,CAAC;AAEF,eAAO,MAAM,mBAAmB,eAClB,UAAU,WACb,OAAO,aAoBjB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@solana-mobile/dapp-store-cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.8",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"main": "./lib/cjs/index.js",
|
|
8
8
|
"module": "./lib/esm/index.js",
|
|
9
9
|
"types": "./lib/types/index.d.ts",
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": ">=18"
|
|
12
|
+
},
|
|
10
13
|
"exports": {
|
|
11
14
|
"import": "./lib/esm/index.js",
|
|
12
15
|
"require": "./lib/cjs/index.js",
|
|
@@ -28,19 +31,24 @@
|
|
|
28
31
|
"@types/commander": "^2.12.2",
|
|
29
32
|
"@types/debug": "^4.1.7",
|
|
30
33
|
"@types/js-yaml": "^4.0.5",
|
|
34
|
+
"@types/terminal-link": "^1.2.0",
|
|
35
|
+
"@types/update-notifier": "^6.0.1",
|
|
31
36
|
"shx": "^0.3.4"
|
|
32
37
|
},
|
|
33
38
|
"dependencies": {
|
|
34
|
-
"@solana-mobile/dapp-store-publishing-tools": "0.1.
|
|
39
|
+
"@solana-mobile/dapp-store-publishing-tools": "0.1.8",
|
|
35
40
|
"@solana/web3.js": "1.68.0",
|
|
36
41
|
"ajv": "^8.11.0",
|
|
42
|
+
"boxen": "^7.0.1",
|
|
37
43
|
"commander": "^9.4.1",
|
|
38
44
|
"debug": "^4.3.4",
|
|
39
45
|
"dotenv": "^16.0.3",
|
|
40
46
|
"esm": "^3.2.25",
|
|
41
47
|
"image-size": "^1.0.2",
|
|
42
48
|
"js-yaml": "^4.1.0",
|
|
43
|
-
"
|
|
49
|
+
"terminal-link": "^3.0.0",
|
|
50
|
+
"tweetnacl": "1.0.3",
|
|
51
|
+
"update-notifier": "^6.0.2"
|
|
44
52
|
},
|
|
45
53
|
"scripts": {
|
|
46
54
|
"clean": "shx mkdir -p lib && shx rm -rf lib",
|
|
@@ -81,8 +81,9 @@ export const createAppCommand = async ({
|
|
|
81
81
|
{ dryRun }
|
|
82
82
|
);
|
|
83
83
|
|
|
84
|
-
|
|
85
|
-
|
|
84
|
+
if (!dryRun) {
|
|
85
|
+
saveToConfig({ app: { address: appAddress } });
|
|
86
|
+
}
|
|
86
87
|
|
|
87
88
|
return { appAddress };
|
|
88
89
|
};
|
|
@@ -5,6 +5,7 @@ import { getConfigFile } from "../../utils.js";
|
|
|
5
5
|
import nacl from "tweetnacl";
|
|
6
6
|
|
|
7
7
|
type PublishRemoveCommandInput = {
|
|
8
|
+
appMintAddress: string;
|
|
8
9
|
releaseMintAddress: string;
|
|
9
10
|
signer: Keypair;
|
|
10
11
|
url: string;
|
|
@@ -14,6 +15,7 @@ type PublishRemoveCommandInput = {
|
|
|
14
15
|
};
|
|
15
16
|
|
|
16
17
|
export const publishRemoveCommand = async ({
|
|
18
|
+
appMintAddress,
|
|
17
19
|
releaseMintAddress,
|
|
18
20
|
signer,
|
|
19
21
|
url,
|
|
@@ -31,6 +33,7 @@ export const publishRemoveCommand = async ({
|
|
|
31
33
|
const connection = new Connection(url);
|
|
32
34
|
const {
|
|
33
35
|
publisher: publisherDetails,
|
|
36
|
+
app: appDetails,
|
|
34
37
|
release: releaseDetails,
|
|
35
38
|
} = await getConfigFile();
|
|
36
39
|
const sign = ((buf: Buffer) =>
|
|
@@ -39,6 +42,7 @@ export const publishRemoveCommand = async ({
|
|
|
39
42
|
await publishRemove(
|
|
40
43
|
{ connection, sign },
|
|
41
44
|
{
|
|
45
|
+
appMintAddress: appMintAddress ?? appDetails.address,
|
|
42
46
|
releaseMintAddress: releaseMintAddress ?? releaseDetails.address,
|
|
43
47
|
publisherDetails,
|
|
44
48
|
requestorIsAuthorized,
|
|
@@ -5,6 +5,7 @@ import nacl from "tweetnacl";
|
|
|
5
5
|
import { getConfigFile } from "../../utils.js";
|
|
6
6
|
|
|
7
7
|
type PublishSubmitCommandInput = {
|
|
8
|
+
appMintAddress: string;
|
|
8
9
|
releaseMintAddress: string;
|
|
9
10
|
signer: Keypair;
|
|
10
11
|
url: string;
|
|
@@ -14,6 +15,7 @@ type PublishSubmitCommandInput = {
|
|
|
14
15
|
};
|
|
15
16
|
|
|
16
17
|
export const publishSubmitCommand = async ({
|
|
18
|
+
appMintAddress,
|
|
17
19
|
releaseMintAddress,
|
|
18
20
|
signer,
|
|
19
21
|
url,
|
|
@@ -36,6 +38,7 @@ export const publishSubmitCommand = async ({
|
|
|
36
38
|
const connection = new Connection(url);
|
|
37
39
|
const {
|
|
38
40
|
publisher: publisherDetails,
|
|
41
|
+
app: appDetails,
|
|
39
42
|
release: releaseDetails,
|
|
40
43
|
solana_mobile_dapp_publisher_portal: solanaMobileDappPublisherPortalDetails,
|
|
41
44
|
} = await getConfigFile();
|
|
@@ -45,6 +48,7 @@ export const publishSubmitCommand = async ({
|
|
|
45
48
|
await publishSubmit(
|
|
46
49
|
{ connection, sign },
|
|
47
50
|
{
|
|
51
|
+
appMintAddress: appMintAddress ?? appDetails.address,
|
|
48
52
|
releaseMintAddress: releaseMintAddress ?? releaseDetails.address,
|
|
49
53
|
publisherDetails,
|
|
50
54
|
solanaMobileDappPublisherPortalDetails,
|
|
@@ -5,6 +5,7 @@ import { getConfigFile } from "../../utils.js";
|
|
|
5
5
|
import nacl from "tweetnacl";
|
|
6
6
|
|
|
7
7
|
type PublishSupportCommandInput = {
|
|
8
|
+
appMintAddress: string;
|
|
8
9
|
releaseMintAddress: string;
|
|
9
10
|
signer: Keypair;
|
|
10
11
|
url: string;
|
|
@@ -14,6 +15,7 @@ type PublishSupportCommandInput = {
|
|
|
14
15
|
};
|
|
15
16
|
|
|
16
17
|
export const publishSupportCommand = async ({
|
|
18
|
+
appMintAddress,
|
|
17
19
|
releaseMintAddress,
|
|
18
20
|
signer,
|
|
19
21
|
url,
|
|
@@ -31,6 +33,7 @@ export const publishSupportCommand = async ({
|
|
|
31
33
|
const connection = new Connection(url);
|
|
32
34
|
const {
|
|
33
35
|
publisher: publisherDetails,
|
|
36
|
+
app: appDetails,
|
|
34
37
|
release: releaseDetails,
|
|
35
38
|
} = await getConfigFile();
|
|
36
39
|
const sign = ((buf: Buffer) =>
|
|
@@ -39,6 +42,7 @@ export const publishSupportCommand = async ({
|
|
|
39
42
|
await publishSupport(
|
|
40
43
|
{ connection, sign },
|
|
41
44
|
{
|
|
45
|
+
appMintAddress: appMintAddress ?? appDetails.address,
|
|
42
46
|
releaseMintAddress: releaseMintAddress ?? releaseDetails.address,
|
|
43
47
|
publisherDetails,
|
|
44
48
|
requestorIsAuthorized,
|
|
@@ -5,6 +5,7 @@ import { getConfigFile } from "../../utils.js";
|
|
|
5
5
|
import nacl from "tweetnacl";
|
|
6
6
|
|
|
7
7
|
type PublishUpdateCommandInput = {
|
|
8
|
+
appMintAddress: string;
|
|
8
9
|
releaseMintAddress: string;
|
|
9
10
|
signer: Keypair;
|
|
10
11
|
url: string;
|
|
@@ -15,6 +16,7 @@ type PublishUpdateCommandInput = {
|
|
|
15
16
|
};
|
|
16
17
|
|
|
17
18
|
export const publishUpdateCommand = async ({
|
|
19
|
+
appMintAddress,
|
|
18
20
|
releaseMintAddress,
|
|
19
21
|
signer,
|
|
20
22
|
url,
|
|
@@ -38,6 +40,7 @@ export const publishUpdateCommand = async ({
|
|
|
38
40
|
const connection = new Connection(url);
|
|
39
41
|
const {
|
|
40
42
|
publisher: publisherDetails,
|
|
43
|
+
app: appDetails,
|
|
41
44
|
release: releaseDetails,
|
|
42
45
|
solana_mobile_dapp_publisher_portal: solanaMobileDappPublisherPortalDetails,
|
|
43
46
|
} = await getConfigFile();
|
|
@@ -47,6 +50,7 @@ export const publishUpdateCommand = async ({
|
|
|
47
50
|
await publishUpdate(
|
|
48
51
|
{ connection, sign },
|
|
49
52
|
{
|
|
53
|
+
appMintAddress: appMintAddress ?? appDetails.address,
|
|
50
54
|
releaseMintAddress: releaseMintAddress ?? releaseDetails.address,
|
|
51
55
|
publisherDetails,
|
|
52
56
|
solanaMobileDappPublisherPortalDetails,
|
package/src/config/index.ts
CHANGED
|
@@ -10,7 +10,7 @@ import { load } from "js-yaml";
|
|
|
10
10
|
import Ajv from "ajv";
|
|
11
11
|
|
|
12
12
|
// eslint-disable-next-line require-extensions/require-extensions
|
|
13
|
-
import schemaJson from "./schema.json";
|
|
13
|
+
import schemaJson from "./schema.json" assert { type: "json" };
|
|
14
14
|
|
|
15
15
|
// TODO: Add version number return here
|
|
16
16
|
export interface CLIConfig {
|
package/src/config/schema.json
CHANGED
|
@@ -150,9 +150,6 @@
|
|
|
150
150
|
"name": {
|
|
151
151
|
"type": "string"
|
|
152
152
|
},
|
|
153
|
-
"short_description": {
|
|
154
|
-
"type": "string"
|
|
155
|
-
},
|
|
156
153
|
"long_description": {
|
|
157
154
|
"type": "string"
|
|
158
155
|
},
|
|
@@ -165,7 +162,6 @@
|
|
|
165
162
|
},
|
|
166
163
|
"required": [
|
|
167
164
|
"name",
|
|
168
|
-
"short_description",
|
|
169
165
|
"long_description",
|
|
170
166
|
"new_in_version",
|
|
171
167
|
"saga_features"
|