@wrongstack/cli 0.318.0 → 0.319.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/data/providers.json +1 -22
- package/dist/{acp-CEQINXWB.js → acp-5ANIAOZC.js} +4 -4
- package/dist/arg-parser.d.ts +4 -0
- package/dist/{auth-3OSF6BMU.js → auth-KF5TAD7V.js} +10 -10
- package/dist/{chunk-GKHUHAIK.js → chunk-42JD25KU.js} +5 -5
- package/dist/{chunk-QYIIOMLE.js → chunk-E4I2TF5S.js} +2 -2
- package/dist/{chunk-37SPPLUD.js → chunk-F5GA2QW2.js} +15 -2
- package/dist/chunk-GGGUZSAU.js +235 -0
- package/dist/{chunk-QC5I4VWZ.js → chunk-H7GABTGS.js} +6 -2
- package/dist/chunk-OZDE3OWD.js +52 -0
- package/dist/chunk-P2OKBDCH.js +1166 -0
- package/dist/chunk-PCBJSXYV.js +65 -0
- package/dist/{chunk-KG4X5F7Z.js → chunk-VFCJOWJB.js} +10 -12
- package/dist/chunk-VWCZL4OH.js +46 -0
- package/dist/{chunk-YX6KUIDF.js → chunk-XHIEA6LG.js} +861 -29
- package/dist/{chunk-BXFYBQKR.js → chunk-XPX432BZ.js} +8 -1
- package/dist/cli-context-LH4QP4W2.js +3369 -0
- package/dist/{cli-main-ILRTNPDP.js → cli-main-72XUFUCL.js} +50 -44
- package/dist/{execution-BN4QIFH6.js → execution-DKJDNPYF.js} +17 -17
- package/dist/index.js +20 -4440
- package/dist/{modeldiag-4NYBRSFP.js → modeldiag-5FRMT6FQ.js} +2 -2
- package/dist/per-subcommand-help-6VCIKDUW.js +23 -0
- package/dist/{plugin-usage-AP7SJCDA.js → plugin-usage-CYUORYM6.js} +2 -2
- package/dist/{plugins-HQ5FU2AM.js → plugins-RV3OBBND.js} +3 -3
- package/dist/pre-launch/first-run.d.ts +51 -0
- package/dist/pre-launch.d.ts +1 -0
- package/dist/{providers-models-663NDPRQ.js → providers-models-OKKQZIWU.js} +2 -2
- package/dist/{sessions-config-P2LK2L32.js → sessions-config-KAMEBVOX.js} +4 -4
- package/dist/short-circuit-flags-U6CJAF6J.js +11 -0
- package/dist/subcommands-J4JMWC5W.js +10 -0
- package/dist/{webui-server-OJLLM6PE.js → webui-server-SY4EQCKD.js} +5 -5
- package/package.json +28 -28
- package/dist/chunk-L6ZNCTRJ.js +0 -1067
package/data/providers.json
CHANGED
|
@@ -255,28 +255,7 @@
|
|
|
255
255
|
}
|
|
256
256
|
}
|
|
257
257
|
},
|
|
258
|
-
"_removeProviders": [
|
|
259
|
-
"anthropic",
|
|
260
|
-
"google",
|
|
261
|
-
"mistral",
|
|
262
|
-
"openrouter",
|
|
263
|
-
"perplexity",
|
|
264
|
-
"groq",
|
|
265
|
-
"xai",
|
|
266
|
-
"cerebras",
|
|
267
|
-
"togetherai",
|
|
268
|
-
"deepinfra",
|
|
269
|
-
"fireworks",
|
|
270
|
-
"replicate",
|
|
271
|
-
"cohere",
|
|
272
|
-
"ai21",
|
|
273
|
-
"huggingface",
|
|
274
|
-
"together",
|
|
275
|
-
"novita",
|
|
276
|
-
"lepton",
|
|
277
|
-
"sambanova",
|
|
278
|
-
"watsonx"
|
|
279
|
-
],
|
|
258
|
+
"_removeProviders": [],
|
|
280
259
|
"_removeModels": {
|
|
281
260
|
"openai": ["gpt-4o-mini", "gpt-4o", "gpt-4", "gpt-4-turbo", "o1", "o1-mini", "o3-mini"],
|
|
282
261
|
"deepseek": ["deepseek-chat", "deepseek-reasoner", "deepseek-v3.2", "deepseek-v4-flash"]
|
|
@@ -3,9 +3,9 @@ import {
|
|
|
3
3
|
loadCachedAcpRegistry,
|
|
4
4
|
refreshAcpRegistry,
|
|
5
5
|
setupProvider
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-F5GA2QW2.js";
|
|
7
|
+
import "./chunk-E4I2TF5S.js";
|
|
8
|
+
import "./chunk-XPX432BZ.js";
|
|
9
9
|
import "./chunk-7OCVIDC7.js";
|
|
10
10
|
|
|
11
11
|
// src/subcommands/handlers/acp.ts
|
|
@@ -913,4 +913,4 @@ ${renderAcpBenchText(result)}
|
|
|
913
913
|
export {
|
|
914
914
|
acpCmd
|
|
915
915
|
};
|
|
916
|
-
//# sourceMappingURL=acp-
|
|
916
|
+
//# sourceMappingURL=acp-5ANIAOZC.js.map
|
package/dist/arg-parser.d.ts
CHANGED
|
@@ -35,6 +35,10 @@ interface SpawnFlags {
|
|
|
35
35
|
* --name=<label> / -n <label> display name
|
|
36
36
|
* --tools=a,b,c restrict the subagent's tool slice
|
|
37
37
|
*
|
|
38
|
+
* All four value flags accept quoted values (`--model="gpt-4o"`); the
|
|
39
|
+
* surrounding quotes are stripped. Without this, a habitually quoted id
|
|
40
|
+
* flows into multiAgentHost.spawn() with the quote characters embedded.
|
|
41
|
+
*
|
|
38
42
|
* Anything after the last flag is the task description.
|
|
39
43
|
*/
|
|
40
44
|
export declare function parseSpawnFlags(input: string): SpawnFlags;
|
|
@@ -13,23 +13,23 @@ import {
|
|
|
13
13
|
runOAuthLoginKind,
|
|
14
14
|
runOAuthLoginMenu,
|
|
15
15
|
validateFamily
|
|
16
|
-
} from "./chunk-
|
|
17
|
-
import {
|
|
18
|
-
restoreFlags
|
|
19
|
-
} from "./chunk-CSAPOCBP.js";
|
|
16
|
+
} from "./chunk-XHIEA6LG.js";
|
|
20
17
|
import {
|
|
21
18
|
renderAuthLocalHelpToString,
|
|
22
19
|
wantsLocalHelp
|
|
23
20
|
} from "./chunk-2VMJ3E5Z.js";
|
|
24
|
-
import {
|
|
25
|
-
parseAuthFlags
|
|
26
|
-
} from "./chunk-L6ZNCTRJ.js";
|
|
27
21
|
import "./chunk-B4JLSXZB.js";
|
|
28
22
|
import "./chunk-VUVOMXWP.js";
|
|
23
|
+
import {
|
|
24
|
+
restoreFlags
|
|
25
|
+
} from "./chunk-CSAPOCBP.js";
|
|
29
26
|
import {
|
|
30
27
|
activeProfileConfigPath
|
|
31
28
|
} from "./chunk-YMXXOOFN.js";
|
|
32
|
-
import
|
|
29
|
+
import {
|
|
30
|
+
parseAuthFlags
|
|
31
|
+
} from "./chunk-GGGUZSAU.js";
|
|
32
|
+
import "./chunk-E4I2TF5S.js";
|
|
33
33
|
import {
|
|
34
34
|
loadConfigProviders,
|
|
35
35
|
maskedKey,
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
normalizeKeys,
|
|
38
38
|
nowIso,
|
|
39
39
|
writeKeysBack
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-XPX432BZ.js";
|
|
41
41
|
import "./chunk-7OCVIDC7.js";
|
|
42
42
|
|
|
43
43
|
// src/subcommands/handlers/auth.ts
|
|
@@ -596,4 +596,4 @@ async function runAuthRemove(deps, providerId) {
|
|
|
596
596
|
export {
|
|
597
597
|
authCmd
|
|
598
598
|
};
|
|
599
|
-
//# sourceMappingURL=auth-
|
|
599
|
+
//# sourceMappingURL=auth-KF5TAD7V.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
PLUGIN_AUDIT_ENTRIES,
|
|
3
|
-
loadExternalPlugins
|
|
4
|
-
} from "./chunk-QC5I4VWZ.js";
|
|
5
1
|
import {
|
|
6
2
|
patchConfig
|
|
7
3
|
} from "./chunk-TYO2OVAD.js";
|
|
4
|
+
import {
|
|
5
|
+
PLUGIN_AUDIT_ENTRIES,
|
|
6
|
+
loadExternalPlugins
|
|
7
|
+
} from "./chunk-H7GABTGS.js";
|
|
8
8
|
|
|
9
9
|
// src/wiring/plugins.ts
|
|
10
10
|
import { join } from "node:path";
|
|
@@ -261,4 +261,4 @@ export {
|
|
|
261
261
|
BUILTIN_PLUGIN_FACTORIES,
|
|
262
262
|
setupPlugins
|
|
263
263
|
};
|
|
264
|
-
//# sourceMappingURL=chunk-
|
|
264
|
+
//# sourceMappingURL=chunk-42JD25KU.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
normalizeKeys,
|
|
4
4
|
nowIso,
|
|
5
5
|
writeKeysBack
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-XPX432BZ.js";
|
|
7
7
|
|
|
8
8
|
// src/auth-menu/openai-codex-oauth.ts
|
|
9
9
|
import { color } from "@wrongstack/core/utils";
|
|
@@ -259,4 +259,4 @@ export {
|
|
|
259
259
|
filterCurrentCodexModelIds,
|
|
260
260
|
isCodexCatalogModel
|
|
261
261
|
};
|
|
262
|
-
//# sourceMappingURL=chunk-
|
|
262
|
+
//# sourceMappingURL=chunk-E4I2TF5S.js.map
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
fallbackCodexProviderModels,
|
|
3
3
|
filterCurrentCodexModelIds,
|
|
4
4
|
isCodexCatalogModel
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-E4I2TF5S.js";
|
|
6
6
|
|
|
7
7
|
// src/acp-registry-cache.ts
|
|
8
8
|
import * as fs from "node:fs/promises";
|
|
@@ -168,12 +168,24 @@ import { ConfigError } from "@wrongstack/core/types";
|
|
|
168
168
|
import {
|
|
169
169
|
buildProviderFactoriesFromRegistry,
|
|
170
170
|
createAiGatewayProviderFactory,
|
|
171
|
+
createSetupProviderFactory,
|
|
171
172
|
installCatalogModelOutputLimits,
|
|
173
|
+
isSetupProvider,
|
|
172
174
|
makeProviderFromConfig as makeProviderFromConfig2,
|
|
175
|
+
setupProviderResolved,
|
|
173
176
|
withCatalogCapabilities
|
|
174
177
|
} from "@wrongstack/providers";
|
|
175
178
|
async function setupProvider(params) {
|
|
176
179
|
const { config, modelsRegistry, logger } = params;
|
|
180
|
+
if (isSetupProvider(config.provider)) {
|
|
181
|
+
const providerRegistry2 = new ProviderRegistry();
|
|
182
|
+
providerRegistry2.register(createSetupProviderFactory());
|
|
183
|
+
return {
|
|
184
|
+
resolvedProvider: setupProviderResolved(),
|
|
185
|
+
provider: providerRegistry2.create({ type: config.provider }),
|
|
186
|
+
providerRegistry: providerRegistry2
|
|
187
|
+
};
|
|
188
|
+
}
|
|
177
189
|
const savedProviderCfg = config.providers?.[config.provider];
|
|
178
190
|
let resolvedProvider = await modelsRegistry.getProvider(config.provider).catch(() => void 0);
|
|
179
191
|
if (!resolvedProvider && savedProviderCfg?.type && savedProviderCfg.type !== config.provider) {
|
|
@@ -234,6 +246,7 @@ async function setupProvider(params) {
|
|
|
234
246
|
}
|
|
235
247
|
const providerRegistry = new ProviderRegistry();
|
|
236
248
|
providerRegistry.register(createAiGatewayProviderFactory());
|
|
249
|
+
providerRegistry.register(createSetupProviderFactory());
|
|
237
250
|
if (config.features.modelsRegistry) {
|
|
238
251
|
try {
|
|
239
252
|
const factories = await buildProviderFactoriesFromRegistry({
|
|
@@ -294,4 +307,4 @@ export {
|
|
|
294
307
|
setupProvider,
|
|
295
308
|
createGracefulShutdown
|
|
296
309
|
};
|
|
297
|
-
//# sourceMappingURL=chunk-
|
|
310
|
+
//# sourceMappingURL=chunk-F5GA2QW2.js.map
|
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
|
|
2
|
+
// src/arg-parser.ts
|
|
3
|
+
var BOOLEAN_FLAGS = /* @__PURE__ */ new Set([
|
|
4
|
+
"yolo",
|
|
5
|
+
"no-yolo",
|
|
6
|
+
"yolo-destructive",
|
|
7
|
+
"confirm-destructive",
|
|
8
|
+
"force-all-yolo",
|
|
9
|
+
"verbose",
|
|
10
|
+
"trace",
|
|
11
|
+
"help",
|
|
12
|
+
"version",
|
|
13
|
+
"yes",
|
|
14
|
+
"no-banner",
|
|
15
|
+
"no-features",
|
|
16
|
+
"tui",
|
|
17
|
+
"no-tui",
|
|
18
|
+
// Recovery switches. `--recover` reopens the most recent session with no
|
|
19
|
+
// trailing `session_end` (see wiring/resume-candidate.ts); `--no-recovery`
|
|
20
|
+
// suppresses it, so a launch script that passes both still starts fresh.
|
|
21
|
+
// Both are boolean so they cannot swallow the next positional token.
|
|
22
|
+
"no-recovery",
|
|
23
|
+
"recover",
|
|
24
|
+
"output-json",
|
|
25
|
+
"prompt",
|
|
26
|
+
"metrics",
|
|
27
|
+
"webui",
|
|
28
|
+
"webui-session-child",
|
|
29
|
+
"simpleui",
|
|
30
|
+
"full-auto",
|
|
31
|
+
"desktop",
|
|
32
|
+
"open",
|
|
33
|
+
"webui-require-token",
|
|
34
|
+
"require-token",
|
|
35
|
+
"no-check",
|
|
36
|
+
"no-models-refresh",
|
|
37
|
+
// (removed: 'director' and 'no-director' — Director Mode is always on)
|
|
38
|
+
"no-autonomy",
|
|
39
|
+
"no-hints",
|
|
40
|
+
"hints",
|
|
41
|
+
"no-menu",
|
|
42
|
+
"no-hooks",
|
|
43
|
+
"skip",
|
|
44
|
+
"skip-index",
|
|
45
|
+
"mouse",
|
|
46
|
+
"no-interactive",
|
|
47
|
+
"token-saving-mode",
|
|
48
|
+
"system-lite",
|
|
49
|
+
"system-pro",
|
|
50
|
+
"hq",
|
|
51
|
+
"hq-allow-exec",
|
|
52
|
+
"tunnel",
|
|
53
|
+
// Opt-in to a non-loopback HQ bind with no token/password configured.
|
|
54
|
+
"insecure-open",
|
|
55
|
+
"strict-port",
|
|
56
|
+
"client",
|
|
57
|
+
// `wstack doctor` booleans. Without these, `--daemons --clear-stale` parses
|
|
58
|
+
// as `daemons="--clear-stale"` and the second flag disappears.
|
|
59
|
+
"daemons",
|
|
60
|
+
"clear-stale",
|
|
61
|
+
// `wstack update` booleans. Keeping these here prevents parseArgs from
|
|
62
|
+
// consuming a following positional token as an accidental flag value.
|
|
63
|
+
"check-only",
|
|
64
|
+
"allow-scripts",
|
|
65
|
+
"lifecycle-scripts",
|
|
66
|
+
"npm",
|
|
67
|
+
"pnpm",
|
|
68
|
+
"yarn",
|
|
69
|
+
"bun",
|
|
70
|
+
// `wstack acp` booleans. Without these, parseArgs treats the value after
|
|
71
|
+
// `--fs`/`--echo` as the flag's value and eats a following positional
|
|
72
|
+
// (e.g. the agent list in `acp bench --fs gemini-cli,codex-cli`).
|
|
73
|
+
"echo",
|
|
74
|
+
"fs",
|
|
75
|
+
// `wstack modeldiag test` booleans. Keep a following positional token from
|
|
76
|
+
// being consumed as the value of one of these switches.
|
|
77
|
+
"all-models",
|
|
78
|
+
"plan",
|
|
79
|
+
"json",
|
|
80
|
+
// Destructive-preview switch (`wstack chronicle prune --dry-run`). It is
|
|
81
|
+
// boolean at every call site, and leaving it out let it consume the next
|
|
82
|
+
// positional — on a command whose whole purpose is to NOT delete.
|
|
83
|
+
"dry-run",
|
|
84
|
+
// Subcommand booleans. A boolean flag missing from this set makes `parseArgs`
|
|
85
|
+
// swallow the FOLLOWING positional as its value (`rewind --all sess123` lost
|
|
86
|
+
// the session id, `export --no-tools out.md` lost the output path), on top of
|
|
87
|
+
// the handler never seeing the flag at all.
|
|
88
|
+
"all",
|
|
89
|
+
"list",
|
|
90
|
+
"latest",
|
|
91
|
+
"disabled",
|
|
92
|
+
"enable",
|
|
93
|
+
"no-tools",
|
|
94
|
+
"no-diagnostics",
|
|
95
|
+
"unsupported",
|
|
96
|
+
"ws",
|
|
97
|
+
"force",
|
|
98
|
+
"no-browser",
|
|
99
|
+
// `wstack auth local` booleans
|
|
100
|
+
"no-key",
|
|
101
|
+
"skip-key",
|
|
102
|
+
"no-probe",
|
|
103
|
+
"skip-probe",
|
|
104
|
+
"probe-only",
|
|
105
|
+
// `wstack models add` capability toggles
|
|
106
|
+
"tools",
|
|
107
|
+
"vision",
|
|
108
|
+
"no-vision",
|
|
109
|
+
"reasoning",
|
|
110
|
+
"no-reasoning",
|
|
111
|
+
"streaming",
|
|
112
|
+
"no-streaming",
|
|
113
|
+
"json-mode",
|
|
114
|
+
"no-json-mode"
|
|
115
|
+
]);
|
|
116
|
+
function parseArgs(argv) {
|
|
117
|
+
const flags = {};
|
|
118
|
+
const positional = [];
|
|
119
|
+
for (let i = 0; i < argv.length; i++) {
|
|
120
|
+
const a = argv[i];
|
|
121
|
+
if (!a) continue;
|
|
122
|
+
if (a === "--") {
|
|
123
|
+
positional.push(...argv.slice(i + 1));
|
|
124
|
+
break;
|
|
125
|
+
}
|
|
126
|
+
if (a.startsWith("--")) {
|
|
127
|
+
const eq = a.indexOf("=");
|
|
128
|
+
if (eq !== -1) {
|
|
129
|
+
flags[a.slice(2, eq)] = a.slice(eq + 1);
|
|
130
|
+
continue;
|
|
131
|
+
}
|
|
132
|
+
const name = a.slice(2);
|
|
133
|
+
if (BOOLEAN_FLAGS.has(name)) {
|
|
134
|
+
flags[name] = true;
|
|
135
|
+
continue;
|
|
136
|
+
}
|
|
137
|
+
if (i + 1 < argv.length && !(argv[i + 1] ?? "").startsWith("-")) {
|
|
138
|
+
flags[name] = argv[++i] ?? "";
|
|
139
|
+
} else {
|
|
140
|
+
flags[name] = true;
|
|
141
|
+
}
|
|
142
|
+
} else if (a.startsWith("-") && a.length === 2) {
|
|
143
|
+
const short = a.slice(1);
|
|
144
|
+
const expand = { v: "verbose", y: "yes", h: "help" };
|
|
145
|
+
flags[expand[short] ?? short] = true;
|
|
146
|
+
} else {
|
|
147
|
+
positional.push(a);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
normalizeSurfaceAliases(flags, positional);
|
|
151
|
+
return { flags, positional };
|
|
152
|
+
}
|
|
153
|
+
function normalizeSurfaceAliases(flags, positional) {
|
|
154
|
+
if (flags["simpleui"]) flags["webui"] = true;
|
|
155
|
+
if (flags["webui-session-child"]) flags["webui"] = true;
|
|
156
|
+
const first = positional[0];
|
|
157
|
+
if (first === "simpleui") {
|
|
158
|
+
flags["simpleui"] = true;
|
|
159
|
+
flags["webui"] = true;
|
|
160
|
+
positional.splice(0, 1);
|
|
161
|
+
return;
|
|
162
|
+
}
|
|
163
|
+
if (first === "webui" || first === "desktop") {
|
|
164
|
+
flags[first] = true;
|
|
165
|
+
positional.splice(0, 1);
|
|
166
|
+
return;
|
|
167
|
+
}
|
|
168
|
+
if (first === "hq" && (positional.length === 1 || positional[1] === "serve") && flags["help"] !== true && flags["version"] !== true) {
|
|
169
|
+
flags["hq"] = true;
|
|
170
|
+
positional.splice(0, positional[1] === "serve" ? 2 : 1);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
function parseAuthFlags(args) {
|
|
174
|
+
const out = { positional: [] };
|
|
175
|
+
for (let i = 0; i < args.length; i++) {
|
|
176
|
+
const a = args[i];
|
|
177
|
+
if (a === "--label") {
|
|
178
|
+
const v = args[++i];
|
|
179
|
+
if (v) out.label = v;
|
|
180
|
+
} else if (a === "--family") {
|
|
181
|
+
const v = args[++i];
|
|
182
|
+
if (v) out.family = v;
|
|
183
|
+
} else if (a === "--base-url") {
|
|
184
|
+
const v = args[++i];
|
|
185
|
+
if (v) out.baseUrl = v;
|
|
186
|
+
} else if (a === "--env") {
|
|
187
|
+
const v = args[++i];
|
|
188
|
+
if (v)
|
|
189
|
+
out.envVars = v.split(",").map((s) => s.trim()).filter(Boolean);
|
|
190
|
+
} else if (a && !a.startsWith("--")) {
|
|
191
|
+
out.positional.push(a);
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
return out;
|
|
195
|
+
}
|
|
196
|
+
function parseSpawnFlags(input) {
|
|
197
|
+
const opts = {};
|
|
198
|
+
let rest = input;
|
|
199
|
+
const consume = (re) => {
|
|
200
|
+
const m = rest.match(re);
|
|
201
|
+
if (m) {
|
|
202
|
+
rest = rest.slice(m[0].length).replace(/^\s+/, "");
|
|
203
|
+
return m;
|
|
204
|
+
}
|
|
205
|
+
return null;
|
|
206
|
+
};
|
|
207
|
+
while (rest.length > 0) {
|
|
208
|
+
let m;
|
|
209
|
+
m = consume(/^(?:--provider|-p)[=\s]+(?:"([^"]+)"|'([^']+)'|(\S+))\s*/);
|
|
210
|
+
if (m) opts.provider = m[1] ?? m[2] ?? m[3];
|
|
211
|
+
else {
|
|
212
|
+
m = consume(/^(?:--model|-m)[=\s]+(?:"([^"]+)"|'([^']+)'|(\S+))\s*/);
|
|
213
|
+
if (m) opts.model = m[1] ?? m[2] ?? m[3];
|
|
214
|
+
else {
|
|
215
|
+
m = consume(/^(?:--name|-n)[=\s]+(?:"([^"]+)"|'([^']+)'|(\S+))\s*/);
|
|
216
|
+
if (m) opts.name = m[1] ?? m[2] ?? m[3];
|
|
217
|
+
else {
|
|
218
|
+
m = consume(/^(?:--tools|-t)[=\s]+(?:"([^"]+)"|'([^']+)'|(\S+))\s*/);
|
|
219
|
+
if (m) {
|
|
220
|
+
const rawTools = m[1] ?? m[2] ?? m[3] ?? "";
|
|
221
|
+
opts.tools = rawTools.split(",").map((t) => t.trim()).filter(Boolean);
|
|
222
|
+
} else break;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
return { description: rest.trim(), opts };
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export {
|
|
231
|
+
parseArgs,
|
|
232
|
+
parseAuthFlags,
|
|
233
|
+
parseSpawnFlags
|
|
234
|
+
};
|
|
235
|
+
//# sourceMappingURL=chunk-GGGUZSAU.js.map
|
|
@@ -241,7 +241,7 @@ import {
|
|
|
241
241
|
resolvePluginTarget as resolvePluginTarget2,
|
|
242
242
|
unpinPluginTrust
|
|
243
243
|
} from "@wrongstack/core/plugin";
|
|
244
|
-
import { atomicWrite } from "@wrongstack/core/utils";
|
|
244
|
+
import { atomicWrite, buildChildEnv } from "@wrongstack/core/utils";
|
|
245
245
|
import {
|
|
246
246
|
PLUGIN_AUDIT_ENTRIES
|
|
247
247
|
} from "@wrongstack/plugins/plugin-audit-catalog";
|
|
@@ -909,6 +909,10 @@ function runPackageManagerInstall(pm, args, cwd) {
|
|
|
909
909
|
invocation.args,
|
|
910
910
|
{
|
|
911
911
|
cwd,
|
|
912
|
+
// H-8 (security report VF-09): this runs npm/pnpm install — including
|
|
913
|
+
// untrusted package lifecycle scripts — with the full inherited
|
|
914
|
+
// environment. Strip credentials via the shared child env.
|
|
915
|
+
env: buildChildEnv(),
|
|
912
916
|
timeout: 3e5,
|
|
913
917
|
maxBuffer: 16 * 1024 * 1024,
|
|
914
918
|
windowsHide: true,
|
|
@@ -992,4 +996,4 @@ export {
|
|
|
992
996
|
PLUGIN_AUDIT_ENTRIES,
|
|
993
997
|
runPluginManagementCommand
|
|
994
998
|
};
|
|
995
|
-
//# sourceMappingURL=chunk-
|
|
999
|
+
//# sourceMappingURL=chunk-H7GABTGS.js.map
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
|
|
2
|
+
// src/subcommands/index.ts
|
|
3
|
+
var loaders = {
|
|
4
|
+
acp: async () => (await import("./acp-5ANIAOZC.js")).acpCmd,
|
|
5
|
+
init: async () => (await import("./init-4JQSG66Q.js")).initCmd,
|
|
6
|
+
auth: async () => (await import("./auth-KF5TAD7V.js")).authCmd,
|
|
7
|
+
update: async () => (await import("./update-K45CS6SS.js")).updateCmd,
|
|
8
|
+
sessions: async () => (await import("./sessions-config-KAMEBVOX.js")).sessionsCmd,
|
|
9
|
+
config: async () => (await import("./sessions-config-KAMEBVOX.js")).configCmd,
|
|
10
|
+
rewind: async () => (await import("./rewind-2FFNOOKS.js")).rewindCmd,
|
|
11
|
+
replay: async () => (await import("./replay-RZXZKP2U.js")).replayCmd,
|
|
12
|
+
audit: async () => (await import("./audit-ZPCLCC3C.js")).auditCmd,
|
|
13
|
+
tools: async () => (await import("./tools-skills-Q4P27URS.js")).toolsCmd,
|
|
14
|
+
skills: async () => (await import("./tools-skills-Q4P27URS.js")).skillsCmd,
|
|
15
|
+
providers: async () => (await import("./providers-models-OKKQZIWU.js")).providersCmd,
|
|
16
|
+
models: async () => (await import("./providers-models-OKKQZIWU.js")).modelsCmd,
|
|
17
|
+
mcp: async () => (await import("./mcp-AQKSASHD.js")).mcpCmd,
|
|
18
|
+
plugin: async () => (await import("./plugin-usage-CYUORYM6.js")).pluginCmd,
|
|
19
|
+
plugins: async () => (await import("./plugin-usage-CYUORYM6.js")).pluginCmd,
|
|
20
|
+
diag: async () => (await import("./diag-doctor-LFCCBPMD.js")).diagCmd,
|
|
21
|
+
doctor: async () => (await import("./diag-doctor-LFCCBPMD.js")).doctorCmd,
|
|
22
|
+
"proxy-status": async () => (await import("./diag-doctor-LFCCBPMD.js")).proxyCmd,
|
|
23
|
+
export: async () => (await import("./export-ROG3DKTZ.js")).exportCmd,
|
|
24
|
+
usage: async () => (await import("./plugin-usage-CYUORYM6.js")).usageCmd,
|
|
25
|
+
version: async () => (await import("./version-help-WMPSEL4U.js")).versionCmd,
|
|
26
|
+
help: async () => (await import("./version-help-WMPSEL4U.js")).helpCmd,
|
|
27
|
+
projects: async () => (await import("./projects-5J727S4L.js")).projectsCmd,
|
|
28
|
+
modeldiag: async () => (await import("./modeldiag-5FRMT6FQ.js")).modeldiagCmd,
|
|
29
|
+
quick: async () => (await import("./quick-XLYLZX4B.js")).quickCmd,
|
|
30
|
+
bench: async () => (await import("./bench-XYG56AMO.js")).benchCmd,
|
|
31
|
+
chronicle: async () => (await import("./chronicle-6EPPMUC5.js")).chronicleCmd,
|
|
32
|
+
hq: async () => (await import("./hq-3GWBFLON.js")).hqCmd,
|
|
33
|
+
mailbox: async () => (await import("./mailbox-serve-VKQIRCCB.js")).mailboxServeCmd,
|
|
34
|
+
permissions: async () => (await import("./permissions-2PWBL4YU.js")).permissionsCmd,
|
|
35
|
+
project: async () => (await import("./project-BLQ3ALVL.js")).projectCmd,
|
|
36
|
+
governance: async () => (await import("./governance-JSGHHA2R.js")).governanceCmd
|
|
37
|
+
};
|
|
38
|
+
var subcommands = Object.fromEntries(
|
|
39
|
+
Object.entries(loaders).map(
|
|
40
|
+
([name, load]) => [
|
|
41
|
+
name,
|
|
42
|
+
async (args, deps) => (await load())(args, deps)
|
|
43
|
+
]
|
|
44
|
+
)
|
|
45
|
+
);
|
|
46
|
+
var subcommandNames = Object.keys(loaders);
|
|
47
|
+
|
|
48
|
+
export {
|
|
49
|
+
subcommands,
|
|
50
|
+
subcommandNames
|
|
51
|
+
};
|
|
52
|
+
//# sourceMappingURL=chunk-OZDE3OWD.js.map
|