SIGTERM to the process tree, SIGKILL after graceMs if it is still running.
Builds run through a shell (shell: true) or npx, so the direct child is
a shell or a launcher and ng build runs as its grandchild. A signal to the
direct child alone leaves the build running. On POSIX the child is started
in its own process group (processGroupOptions) and the whole group
is signalled; Windows has no process groups, there only the child is
signalled.
The SIGKILL goes to the group even when the leader (the shell) has already
exited, because a build that ignores SIGTERM outlives its shell. The timer
does not keep the process alive.
SIGTERM to the process tree, SIGKILL after
graceMsif it is still running.Builds run through a shell (
shell: true) ornpx, so the direct child is a shell or a launcher andng buildruns as its grandchild. A signal to the direct child alone leaves the build running. On POSIX the child is started in its own process group (processGroupOptions) and the whole group is signalled; Windows has no process groups, there only the child is signalled.The SIGKILL goes to the group even when the leader (the shell) has already exited, because a build that ignores SIGTERM outlives its shell. The timer does not keep the process alive.