svamp-cli 0.2.39 → 0.2.41
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/cli.mjs
CHANGED
|
@@ -281,7 +281,7 @@ async function main() {
|
|
|
281
281
|
console.error("svamp process: Process commands are not available in sandboxed sessions.");
|
|
282
282
|
process.exit(1);
|
|
283
283
|
}
|
|
284
|
-
const { processCommand } = await import('./commands-
|
|
284
|
+
const { processCommand } = await import('./commands-DNT-V_p6.mjs');
|
|
285
285
|
let machineId;
|
|
286
286
|
const processArgs = args.slice(1);
|
|
287
287
|
const mIdx = processArgs.findIndex((a) => a === "--machine" || a === "-m");
|
|
@@ -299,7 +299,7 @@ async function main() {
|
|
|
299
299
|
} else if (!subcommand || subcommand === "start") {
|
|
300
300
|
await handleInteractiveCommand();
|
|
301
301
|
} else if (subcommand === "--version" || subcommand === "-v") {
|
|
302
|
-
const pkg = await import('./package-
|
|
302
|
+
const pkg = await import('./package-CZ43ufBM.mjs').catch(() => ({ default: { version: "unknown" } }));
|
|
303
303
|
console.log(`svamp version: ${pkg.default.version}`);
|
|
304
304
|
} else {
|
|
305
305
|
console.error(`Unknown command: ${subcommand}`);
|
|
@@ -1392,6 +1392,27 @@ async function applyClaudeAuthFlags(argv) {
|
|
|
1392
1392
|
async function handleDaemonAuthCommand(argv) {
|
|
1393
1393
|
const sub = (argv[0] || "status").toLowerCase();
|
|
1394
1394
|
const mod = await import('./run-CRwkPQDW.mjs').then(function (n) { return n.k; });
|
|
1395
|
+
if (sub === "--help" || sub === "-h" || sub === "help") {
|
|
1396
|
+
console.log(`
|
|
1397
|
+
svamp daemon auth \u2014 Configure how Claude subprocesses authenticate
|
|
1398
|
+
|
|
1399
|
+
Subcommands:
|
|
1400
|
+
svamp daemon auth Show current mode + base URL + redacted API key
|
|
1401
|
+
svamp daemon auth use-hypha-proxy Route Claude through the Hypha LLM proxy
|
|
1402
|
+
(https://proxy.hypha.aicell.io) using HYPHA_TOKEN.
|
|
1403
|
+
Token is resolved live at each spawn, so a
|
|
1404
|
+
\`svamp login\` refresh takes effect immediately.
|
|
1405
|
+
svamp daemon auth use-login Use ~/.claude credentials written by \`claude login\`.
|
|
1406
|
+
Removes managed ANTHROPIC_BASE_URL / ANTHROPIC_API_KEY.
|
|
1407
|
+
svamp daemon auth set <URL> <KEY> Use a custom Anthropic gateway. URL must NOT end
|
|
1408
|
+
in /v1 (the SDK appends it automatically).
|
|
1409
|
+
|
|
1410
|
+
All mutations are persisted to ~/.svamp/.env. Run \`svamp daemon restart\` afterwards
|
|
1411
|
+
(or use the equivalent flags on \`svamp daemon start/restart\` to configure + restart in
|
|
1412
|
+
one step: --use-hypha-proxy / --use-claude-login / --anthropic-base-url URL --anthropic-api-key KEY).
|
|
1413
|
+
`);
|
|
1414
|
+
return;
|
|
1415
|
+
}
|
|
1395
1416
|
if (sub === "status" || sub === "show") {
|
|
1396
1417
|
const s = mod.getClaudeAuthStatus();
|
|
1397
1418
|
console.log(`Claude auth mode: ${s.mode}`);
|
|
@@ -302,7 +302,7 @@ async function applyCommand(args, machineId) {
|
|
|
302
302
|
const spec = await readSpecFile(filePath);
|
|
303
303
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
304
304
|
try {
|
|
305
|
-
const result = await machine.processApply({ spec
|
|
305
|
+
const result = await machine.processApply({ spec });
|
|
306
306
|
const { action, info } = result;
|
|
307
307
|
if (action === "no-change") {
|
|
308
308
|
console.log(`process/${info.spec.name} unchanged`);
|
|
@@ -326,7 +326,7 @@ async function listCommand(args, machineId) {
|
|
|
326
326
|
const json = hasFlag(args, "--json");
|
|
327
327
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
328
328
|
try {
|
|
329
|
-
const processes = await machine.processList({
|
|
329
|
+
const processes = await machine.processList({});
|
|
330
330
|
if (json) {
|
|
331
331
|
console.log(JSON.stringify(processes, null, 2));
|
|
332
332
|
} else {
|
|
@@ -346,7 +346,7 @@ async function getCommand(args, machineId) {
|
|
|
346
346
|
const outFile = getFlag(args, "--save");
|
|
347
347
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
348
348
|
try {
|
|
349
|
-
const info = await machine.processGet({ idOrName
|
|
349
|
+
const info = await machine.processGet({ idOrName });
|
|
350
350
|
if (!info) {
|
|
351
351
|
console.error(`Error: process '${idOrName}' not found`);
|
|
352
352
|
process.exit(1);
|
|
@@ -386,7 +386,7 @@ async function startCommand(args, machineId) {
|
|
|
386
386
|
if (cmdArgs.length === 0) {
|
|
387
387
|
const { server: server2, machine: machine2 } = await connectAndGetMachine(machineId);
|
|
388
388
|
try {
|
|
389
|
-
await machine2.processStart({ idOrName
|
|
389
|
+
await machine2.processStart({ idOrName });
|
|
390
390
|
console.log(`Started '${idOrName}'`);
|
|
391
391
|
} finally {
|
|
392
392
|
await server2.disconnect();
|
|
@@ -443,7 +443,7 @@ async function startCommand(args, machineId) {
|
|
|
443
443
|
const saveFile = getFlag(flagArgs, "--save");
|
|
444
444
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
445
445
|
try {
|
|
446
|
-
const result = await machine.processApply({ spec
|
|
446
|
+
const result = await machine.processApply({ spec });
|
|
447
447
|
const { info } = result;
|
|
448
448
|
console.log(`Started '${info.spec.name}' (id: ${info.spec.id}, pid: ${info.state.pid ?? "\u2014"})`);
|
|
449
449
|
if (keepAlive) console.log(" Keep-alive: enabled");
|
|
@@ -465,7 +465,7 @@ async function stopCommand(args, machineId) {
|
|
|
465
465
|
}
|
|
466
466
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
467
467
|
try {
|
|
468
|
-
await machine.processStop({ idOrName
|
|
468
|
+
await machine.processStop({ idOrName });
|
|
469
469
|
console.log(`Stopped '${idOrName}'`);
|
|
470
470
|
} finally {
|
|
471
471
|
await server.disconnect();
|
|
@@ -479,7 +479,7 @@ async function restartCommand(args, machineId) {
|
|
|
479
479
|
}
|
|
480
480
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
481
481
|
try {
|
|
482
|
-
await machine.processRestart({ idOrName
|
|
482
|
+
await machine.processRestart({ idOrName });
|
|
483
483
|
console.log(`Restarted '${idOrName}'`);
|
|
484
484
|
} finally {
|
|
485
485
|
await server.disconnect();
|
|
@@ -493,7 +493,7 @@ async function deleteCommand(args, machineId) {
|
|
|
493
493
|
}
|
|
494
494
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
495
495
|
try {
|
|
496
|
-
await machine.processRemove({ idOrName
|
|
496
|
+
await machine.processRemove({ idOrName });
|
|
497
497
|
console.log(`Deleted '${idOrName}'`);
|
|
498
498
|
} finally {
|
|
499
499
|
await server.disconnect();
|
|
@@ -508,7 +508,7 @@ async function logsCommand(args, machineId) {
|
|
|
508
508
|
const last = parseIntFlag(args, "--last", 50);
|
|
509
509
|
const { server, machine } = await connectAndGetMachine(machineId);
|
|
510
510
|
try {
|
|
511
|
-
const lines = await machine.processLogs({ idOrName, last
|
|
511
|
+
const lines = await machine.processLogs({ idOrName, last });
|
|
512
512
|
if (lines.length === 0) console.log("(no output yet)");
|
|
513
513
|
else console.log(lines.join("\n"));
|
|
514
514
|
} finally {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
var name = "svamp-cli";
|
|
2
|
-
var version = "0.2.
|
|
2
|
+
var version = "0.2.41";
|
|
3
3
|
var description = "Svamp CLI — AI workspace daemon on Hypha Cloud";
|
|
4
4
|
var author = "Amun AI AB";
|
|
5
5
|
var license = "SEE LICENSE IN LICENSE";
|
|
@@ -29,7 +29,7 @@ var scripts = {
|
|
|
29
29
|
var dependencies = {
|
|
30
30
|
"@agentclientprotocol/sdk": "^0.14.1",
|
|
31
31
|
"@modelcontextprotocol/sdk": "^1.25.3",
|
|
32
|
-
"hypha-rpc": "0.21.
|
|
32
|
+
"hypha-rpc": "0.21.40",
|
|
33
33
|
"node-pty": "1.2.0-beta.11",
|
|
34
34
|
ws: "^8.18.0",
|
|
35
35
|
yaml: "^2.8.2",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "svamp-cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.41",
|
|
4
4
|
"description": "Svamp CLI — AI workspace daemon on Hypha Cloud",
|
|
5
5
|
"author": "Amun AI AB",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@agentclientprotocol/sdk": "^0.14.1",
|
|
32
32
|
"@modelcontextprotocol/sdk": "^1.25.3",
|
|
33
|
-
"hypha-rpc": "0.21.
|
|
33
|
+
"hypha-rpc": "0.21.40",
|
|
34
34
|
"node-pty": "1.2.0-beta.11",
|
|
35
35
|
"ws": "^8.18.0",
|
|
36
36
|
"yaml": "^2.8.2",
|