MCPcopy Index your code
hub / github.com/callstack/agent-device / readStoredAppLogProcessMeta

Function readStoredAppLogProcessMeta

src/daemon/app-log-process.ts:66–75  ·  view source on GitHub ↗
(
  pidPath: string | undefined,
)

Source from the content-addressed store, hash-verified

64}
65
66export function readStoredAppLogProcessMeta(
67 pidPath: string | undefined,
68): StoredAppLogProcessMeta | null {
69 if (!pidPath || !fs.existsSync(pidPath)) return null;
70 try {
71 return parsePidFile(fs.readFileSync(pidPath, 'utf8'));
72 } catch {
73 return null;
74 }
75}
76
77export function writePidFile(pidPath: string | undefined, pid: number): void {
78 if (!pidPath) return;

Callers 1

Calls 1

parsePidFileFunction · 0.85

Tested by

no test coverage detected