MCPcopy Create free account
hub / github.com/garrytan/gstack / searchWithPath

Function searchWithPath

test/gstack-decision-bins.test.ts:114–122  ·  view source on GitHub ↗
(args: string, pathPrefix?: string)

Source from the content-addressed store, hash-verified

112 return d;
113 }
114 function searchWithPath(args: string, pathPrefix?: string): string {
115 const env = { ...process.env, GSTACK_HOME: tmpDir } as NodeJS.ProcessEnv;
116 if (pathPrefix) env.PATH = `${pathPrefix}:${process.env.PATH}`;
117 try {
118 return execSync(`${SEARCH} ${args}`, { cwd: ROOT, env, encoding: "utf-8", timeout: 20000 }).trim();
119 } catch {
120 return "";
121 }
122 }
123
124 test("--semantic without --query behaves like a normal search (no gbrain spawn)", () => {
125 log('{"decision":"reliable-alpha","scope":"repo","source":"user"}');

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected