MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / readLockPid

Function readLockPid

__tests__/mcp-daemon.test.ts:147–153  ·  view source on GitHub ↗
(root: string)

Source from the content-addressed store, hash-verified

145}
146
147function readLockPid(root: string): number | null {
148 try {
149 const raw = fs.readFileSync(path.join(root, '.codegraph', 'daemon.pid'), 'utf8');
150 const info = JSON.parse(raw);
151 return typeof info.pid === 'number' ? info.pid : null;
152 } catch { return null; }
153}
154
155function readDaemonLog(root: string): string {
156 try { return fs.readFileSync(path.join(root, '.codegraph', 'daemon.log'), 'utf8'); }

Callers 1

mcp-daemon.test.tsFile · 0.85

Calls 1

joinMethod · 0.45

Tested by

no test coverage detected