MCPcopy Create free account
hub / github.com/cli/cli / waitForExit

Function waitForExit

evals/src/smoke.ts:56–61  ·  view source on GitHub ↗
(child: ChildProcess)

Source from the content-addressed store, hash-verified

54}
55
56function waitForExit(child: ChildProcess): Promise<{ code: number | null; signal: NodeJS.Signals | null }> {
57 return new Promise((resolveExit, reject) => {
58 child.once("error", reject);
59 child.once("close", (code, signal) => resolveExit({ code, signal }));
60 });
61}
62
63export async function main(argv = process.argv.slice(2)): Promise<void> {
64 const options = parse(argv);

Callers 1

mainFunction · 0.85

Calls 1

onceMethod · 0.80

Tested by

no test coverage detected