fix: harden atomic file writes (#1453)
Co-authored-by: Bohdan Triapitsyn <artmore@protonmail.com>
This commit is contained in:
committed by
GitHub
co-authored by
Bohdan Triapitsyn
parent
c2ca844402
commit
e6338e5c71
@@ -146,13 +146,6 @@ async function shutdown(exitCode = 0) {
|
||||
if (shuttingDown) return;
|
||||
shuttingDown = true;
|
||||
await Promise.all([stopChildTree(api), stopChildTree(vite)]);
|
||||
// Clean up orphaned OpenCode processes that weren't killed by
|
||||
// the Express server's shutdown (e.g. when nodemon is killed first).
|
||||
try {
|
||||
spawnSync('pkill', ['-f', 'opencode serve'], { stdio: 'ignore' });
|
||||
} catch {
|
||||
// best-effort
|
||||
}
|
||||
process.exit(exitCode);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user