1'use strict'; 2 3// Handle a Promise from running code that potentially does Top-Level Await. 4// In that case, it makes sense to set the exit code to a specific non-zero 5// value if the main code never finishes running. 6function handleProcessExit() { 7 if (process.exitCode == null) process.exitCode = 13; 8} 9 10module.exports = { 11 handleProcessExit, 12}; 13