Skip to content

Commit

Permalink
fix(scripts): kill processes in addition to closing them on errors
Browse files Browse the repository at this point in the history
  • Loading branch information
umbopepato committed Apr 2, 2021
1 parent 3b63600 commit 1b437b6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/run_commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ export async function runCommands(
try {
await _runCommands(commands as Array<Command | ParallelCommands>);
} catch (e) {
runningProcesses.forEach((p) => p.close());
runningProcesses.forEach((p) => {
p.kill(Deno.Signal.SIGKILL);
p.close();
});
throw e;
}
}
Expand Down

0 comments on commit 1b437b6

Please sign in to comment.