MCPcopy Index your code
hub / github.com/getsentry/XcodeBuildMCP / parseArgs

Function parseArgs

scripts/probe-xcode-mcpbridge.ts:6–22  ·  view source on GitHub ↗
(argv: string[])

Source from the content-addressed store, hash-verified

4import process from 'node:process';
5
6function parseArgs(argv: string[]): { limit: number; callWindows: boolean } {
7 let limit = 20;
8 let callWindows = true;
9 for (let i = 2; i < argv.length; i += 1) {
10 const arg = argv[i];
11 if (arg === '--limit' && argv[i + 1]) {
12 limit = Number(argv[i + 1]);
13 i += 1;
14 continue;
15 }
16 if (arg === '--no-windows') {
17 callWindows = false;
18 continue;
19 }
20 }
21 return { limit: Number.isFinite(limit) ? limit : 20, callWindows };
22}
23
24function mapXcodeEnvForMcpBridge(env: NodeJS.ProcessEnv): Record<string, string> {
25 const mapped: Record<string, string> = {};

Callers 1

mainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected