MCPcopy Create free account
hub / github.com/cortexkit/magic-context / parseHarnessFlag

Function parseHarnessFlag

packages/cli/src/lib/harness-select.ts:14–20  ·  view source on GitHub ↗
(argv: string[])

Source from the content-addressed store, hash-verified

12import { log, selectMany, selectOne } from "./prompts";
13
14function parseHarnessFlag(argv: string[]): HarnessKind | null {
15 const idx = argv.indexOf("--harness");
16 if (idx === -1 || idx === argv.length - 1) return null;
17 const value = argv[idx + 1];
18 if (value === "opencode" || value === "pi") return value;
19 return null;
20}
21
22export interface ResolveOptions {
23 /** Allow the user to select multiple harnesses at once. Setup defaults to single. */

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected