@vultisig/cli 4.7.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/dist/index.js +25 -10
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,15 @@
|
|
|
1
1
|
# @vultisig/cli
|
|
2
2
|
|
|
3
|
+
## 5.0.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`3ed3179`](https://github.com/vultisig/vultisig-sdk/commit/3ed31790b62b4c7f7b1fdbc477f72edebbb2e097), [`8929244`](https://github.com/vultisig/vultisig-sdk/commit/8929244cdb3b21059a46eabac6d4d9684e18a633), [`514e31f`](https://github.com/vultisig/vultisig-sdk/commit/514e31f084c241792f3a9b2436074c324a909c0f), [`952bcdf`](https://github.com/vultisig/vultisig-sdk/commit/952bcdf767621908d1db58d624a4d41a17e7108b)]:
|
|
8
|
+
- @vultisig/sdk@5.0.0
|
|
9
|
+
- @vultisig/core-chain@2.38.0
|
|
10
|
+
- @vultisig/client-shared@0.3.4
|
|
11
|
+
- @vultisig/rujira@67.0.0
|
|
12
|
+
|
|
3
13
|
## 4.7.0
|
|
4
14
|
|
|
5
15
|
### Patch Changes
|
package/dist/index.js
CHANGED
|
@@ -8545,6 +8545,14 @@ function classifyError(err) {
|
|
|
8545
8545
|
case VaultImportErrorCode.PASSWORD_REQUIRED:
|
|
8546
8546
|
case VaultImportErrorCode.INVALID_PASSWORD:
|
|
8547
8547
|
return new AuthRequiredError(err.message);
|
|
8548
|
+
case VaultImportErrorCode.DUPLICATE_VAULT:
|
|
8549
|
+
return new UsageError("Vault already exists. Re-run the import with --replace to replace a compatible share.");
|
|
8550
|
+
case VaultImportErrorCode.STALE_SHARE:
|
|
8551
|
+
return new UsageError("Import refused: this backup contains a stale or different local vault share.");
|
|
8552
|
+
case VaultImportErrorCode.OTHER_DEVICE_SHARE:
|
|
8553
|
+
return new UsageError("Import refused: this backup belongs to another device in the same vault.");
|
|
8554
|
+
case VaultImportErrorCode.EXISTING_VAULT_PASSWORD_REQUIRED:
|
|
8555
|
+
return new AuthRequiredError("Unlock the existing local vault before replacing its share.");
|
|
8548
8556
|
default:
|
|
8549
8557
|
return new UsageError(err.message);
|
|
8550
8558
|
}
|
|
@@ -11473,7 +11481,7 @@ Important: Save your vault backup file (.vult) in a secure location.`);
|
|
|
11473
11481
|
throw err;
|
|
11474
11482
|
}
|
|
11475
11483
|
}
|
|
11476
|
-
async function executeImport(ctx2, file, flagPassword) {
|
|
11484
|
+
async function executeImport(ctx2, file, flagPassword, replace = false) {
|
|
11477
11485
|
let password = flagPassword || process.env.VAULT_PASSWORD || "";
|
|
11478
11486
|
if (!password) {
|
|
11479
11487
|
const answers = await prompt([
|
|
@@ -11488,7 +11496,11 @@ async function executeImport(ctx2, file, flagPassword) {
|
|
|
11488
11496
|
}
|
|
11489
11497
|
const spinner = createSpinner("Importing vault...");
|
|
11490
11498
|
const vultContent = await fs2.readFile(file, "utf-8");
|
|
11491
|
-
const vault = await ctx2.sdk.importVault(
|
|
11499
|
+
const vault = await ctx2.sdk.importVault(
|
|
11500
|
+
vultContent,
|
|
11501
|
+
password || void 0,
|
|
11502
|
+
replace ? { conflictResolution: "replace" } : void 0
|
|
11503
|
+
);
|
|
11492
11504
|
setupVaultEvents(vault);
|
|
11493
11505
|
await ctx2.setActiveVault(vault);
|
|
11494
11506
|
spinner.succeed(`Vault imported: ${vault.name}`);
|
|
@@ -19178,7 +19190,7 @@ var cachedVersion = null;
|
|
|
19178
19190
|
function getVersion() {
|
|
19179
19191
|
if (cachedVersion) return cachedVersion;
|
|
19180
19192
|
if (true) {
|
|
19181
|
-
cachedVersion = "
|
|
19193
|
+
cachedVersion = "5.0.0";
|
|
19182
19194
|
return cachedVersion;
|
|
19183
19195
|
}
|
|
19184
19196
|
try {
|
|
@@ -20275,12 +20287,14 @@ Error: ${error2.message}`));
|
|
|
20275
20287
|
console.log(`Status: ${status}`);
|
|
20276
20288
|
}
|
|
20277
20289
|
async importVault(args) {
|
|
20278
|
-
|
|
20279
|
-
|
|
20290
|
+
const replace = args.includes("--replace");
|
|
20291
|
+
const fileArgs = args.filter((arg) => arg !== "--replace");
|
|
20292
|
+
if (fileArgs.length === 0) {
|
|
20293
|
+
console.log(chalk14.yellow("Usage: import [--replace] <file>"));
|
|
20280
20294
|
return;
|
|
20281
20295
|
}
|
|
20282
|
-
const filePath =
|
|
20283
|
-
const vault = await executeImport(this.ctx, filePath);
|
|
20296
|
+
const filePath = fileArgs.join(" ");
|
|
20297
|
+
const vault = await executeImport(this.ctx, filePath, void 0, replace);
|
|
20284
20298
|
this.ctx.addVault(vault);
|
|
20285
20299
|
this.eventBuffer.setupVaultListeners(vault);
|
|
20286
20300
|
}
|
|
@@ -21140,16 +21154,17 @@ program2.command("add-mldsa").description("Add ML-DSA (post-quantum) keys to the
|
|
|
21140
21154
|
});
|
|
21141
21155
|
})
|
|
21142
21156
|
);
|
|
21143
|
-
program2.command("import <file>").description("Import vault from .vult file").option("--password <password>", "Password to decrypt the vault file").addHelpText(
|
|
21157
|
+
program2.command("import <file>").description("Import vault from .vult file").option("--password <password>", "Password to decrypt the vault file").option("--replace", "Replace an existing compatible local vault share").addHelpText(
|
|
21144
21158
|
"after",
|
|
21145
21159
|
`
|
|
21146
21160
|
Examples:
|
|
21147
21161
|
vultisig import ~/vault-backup.vult
|
|
21148
|
-
vultisig import ~/vault-backup.vult --password mypassword
|
|
21162
|
+
vultisig import ~/vault-backup.vult --password mypassword
|
|
21163
|
+
vultisig import ~/vault-backup.vult --replace`
|
|
21149
21164
|
).action(
|
|
21150
21165
|
withExit(async (file, options) => {
|
|
21151
21166
|
const context = await init(program2.opts().vault);
|
|
21152
|
-
await executeImport(context, file, options.password);
|
|
21167
|
+
await executeImport(context, file, options.password, options.replace);
|
|
21153
21168
|
})
|
|
21154
21169
|
);
|
|
21155
21170
|
var createFromSeedphraseCmd = program2.command("create-from-seedphrase").description("Create vault from BIP39 seedphrase");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vultisig/cli",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "The self-custody MPC wallet CLI for AI coding agents (Claude Code, Cursor, OpenCode). Natural-language agent mode, 36+ chains, DKLS23 threshold signatures. Seedless.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -74,10 +74,10 @@
|
|
|
74
74
|
"@msgpack/msgpack": "^3.1.2",
|
|
75
75
|
"@napi-rs/keyring": "^1.3.0",
|
|
76
76
|
"@noble/hashes": "^2.2.0",
|
|
77
|
-
"@vultisig/client-shared": "^0.3.
|
|
78
|
-
"@vultisig/core-chain": "^2.
|
|
79
|
-
"@vultisig/rujira": "^
|
|
80
|
-
"@vultisig/sdk": "^
|
|
77
|
+
"@vultisig/client-shared": "^0.3.4",
|
|
78
|
+
"@vultisig/core-chain": "^2.38.0",
|
|
79
|
+
"@vultisig/rujira": "^67.0.0",
|
|
80
|
+
"@vultisig/sdk": "^5.0.0",
|
|
81
81
|
"chalk": "^5.6.2",
|
|
82
82
|
"cli-table3": "^0.6.5",
|
|
83
83
|
"commander": "^15.0.0",
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"@types/node": "^26.1.1",
|
|
96
96
|
"@types/tabtab": "^3.0.4",
|
|
97
97
|
"@types/ws": "^8.18.1",
|
|
98
|
-
"@vultisig/core-mpc": "^1.20.
|
|
98
|
+
"@vultisig/core-mpc": "^1.20.2",
|
|
99
99
|
"esbuild": "^0.28.1",
|
|
100
100
|
"ethers": "^6.17.0",
|
|
101
101
|
"node-pty": "^1.1.0",
|