(args: string[], cwd: string)
| 32 | } |
| 33 | |
| 34 | function runCodegraph(args: string[], cwd: string): string { |
| 35 | return execFileSync(process.execPath, [BIN, ...args], { |
| 36 | cwd, |
| 37 | encoding: 'utf-8', |
| 38 | env: { ...process.env, CODEGRAPH_NO_DAEMON: '1' }, |
| 39 | stdio: ['ignore', 'pipe', 'pipe'], |
| 40 | }); |
| 41 | } |
| 42 | |
| 43 | function graphCounts(dir: string): { nodes: number; edges: number } { |
| 44 | const cg = CodeGraph.openSync(dir); |