Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/nx/src/executors/run-commands/running-tasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ class RunningNodeProcess implements RunningTask {
process.on('SIGINT', () => {
this.childProcess.kill('SIGTERM');
// we exit here because we don't need to write anything to cache.
process.exit(signalToCode('SIGINT'));
process.exitCode = signalToCode('SIGINT');
});
process.on('SIGTERM', () => {
this.childProcess.kill('SIGTERM');
Expand Down Expand Up @@ -702,7 +702,7 @@ function registerProcessListener(
process.on('SIGINT', () => {
runningTask.kill('SIGTERM');
// we exit here because we don't need to write anything to cache.
process.exit(signalToCode('SIGINT'));
process.exitCode = signalToCode('SIGINT');
});
process.on('SIGTERM', () => {
runningTask.kill('SIGTERM');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ export class ForkedProcessTaskRunner {
this.cleanup('SIGTERM');
process.off('message', messageHandler);
// we exit here because we don't need to write anything to cache.
process.exit(signalToCode('SIGINT'));
process.exitCode = signalToCode('SIGINT');
});
process.once('SIGTERM', () => {
this.cleanup('SIGTERM');
Expand Down
4 changes: 2 additions & 2 deletions packages/nx/src/tasks-runner/task-orchestrator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -750,7 +750,7 @@ export class TaskOrchestrator {
runningTask.onExit((code) => {
if (!this.tuiEnabled) {
if (code > 128) {
process.exit(code);
process.exitCode = code;
}
}
res();
Expand Down Expand Up @@ -816,7 +816,7 @@ export class TaskOrchestrator {
childProcess.onExit((code) => {
if (!this.tuiEnabled) {
if (code > 128) {
process.exit(code);
process.exitCode = code;
}
}
res();
Expand Down