MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / terminatePid

Function terminatePid

apps/cli/src/daemon-state.ts:394–403  ·  view source on GitHub ↗
(pid: number)

Source from the content-addressed store, hash-verified

392};
393
394export const terminatePid = (pid: number): Effect.Effect<void, Error> =>
395 Effect.try({
396 try: () => {
397 process.kill(pid, "SIGTERM");
398 },
399 catch: (cause) =>
400 cause instanceof Error
401 ? cause
402 : new Error(`Failed to terminate pid ${pid}: ${String(cause)}`),
403 });

Callers 3

stopDaemonFunction · 0.90
runDaemonSessionFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected