MCPcopy Create free account
hub / github.com/Gan-Xing/CodexBridge / stop

Function stop

packages/codex-native-api/src/cli.ts:39–47  ·  view source on GitHub ↗
(signal: string)

Source from the content-addressed store, hash-verified

37
38 let stopped = false;
39 const stop = async (signal: string) => {
40 if (stopped) {
41 return;
42 }
43 stopped = true;
44 process.stdout.write(`stopping: ${signal}\n`);
45 await service.stop();
46 process.exit(0);
47 };
48
49 process.on('SIGINT', () => { void stop('SIGINT'); });
50 process.on('SIGTERM', () => { void stop('SIGTERM'); });

Callers 1

serveFunction · 0.70

Calls 2

writeMethod · 0.80
stopMethod · 0.65

Tested by

no test coverage detected