fix: lowercased tool names in argument parsing

Fixes #324.
This commit is contained in:
can1357
2026-03-07 23:53:16 +01:00
parent 95df9f6f3e
commit 7d5a230e26
10 changed files with 33 additions and 9 deletions
+4 -1
View File
@@ -108,7 +108,10 @@ export function parseArgs(args: string[], extensionFlags?: Map<string, { type: "
} else if (arg === "--no-pty") {
result.noPty = true;
} else if (arg === "--tools" && i + 1 < args.length) {
const toolNames = args[++i].split(",").map(s => s.trim());
const toolNames = args[++i]
.split(",")
.map(s => s.trim().toLowerCase())
.filter(Boolean);
const validTools: string[] = [];
for (const name of toolNames) {
if (name in BUILTIN_TOOLS) {