test(ast-grep-mcp): batch 12 (3 files)

This commit is contained in:
YeonGyu-Kim
2026-05-30 19:12:03 +09:00
parent a8866f685d
commit 6ec6c822a7
3 changed files with 32 additions and 19 deletions
+8 -2
View File
@@ -1,14 +1,20 @@
#!/usr/bin/env node
import { argv, stderr } from "node:process";
import { writeMcpLifecycleLog } from "./mcp-lifecycle-log";
import { runMcpStdioServer } from "./mcp";
async function main(): Promise<void> {
const [command = "mcp"] = argv.slice(2);
if (command === "mcp") {
await runMcpStdioServer();
await runMcpStdioServer(process.stdin, process.stdout, {}, {
log: writeMcpLifecycleLog,
onIdleTimeout: () => {
process.exit(0);
},
});
return;
}
stderr.write("Usage: ast-grep-mcp [mcp]\n");
stderr.write("Usage: omo-ast-grep [mcp]\n");
process.exitCode = 2;
}