MCPcopy
hub / github.com/electron/forge / forgeSpawnWrapper

Function forgeSpawnWrapper

packages/api/core/src/api/start.ts:264–286  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

262 };
263
264 const forgeSpawnWrapper = async () => {
265 const spawned = await forgeSpawn();
266 // When the child app is closed we should stop listening for stdin
267 if (spawned) {
268 if (interactive && process.stdin.isPaused()) {
269 process.stdin.resume();
270 }
271 spawned.on('exit', () => {
272 if (spawned.restarted) {
273 return;
274 }
275
276 if (interactive && !process.stdin.isPaused()) {
277 process.stdin.pause();
278 }
279 });
280 } else if (interactive && !process.stdin.isPaused()) {
281 process.stdin.pause();
282 }
283
284 lastSpawned = spawned;
285 return lastSpawned;
286 };
287
288 if (interactive) {
289 process.stdin.on('data', (data) => {

Callers 1

start.tsFile · 0.85

Calls 1

forgeSpawnFunction · 0.85

Tested by

no test coverage detected