Skip to content
Myr

fixes exit code from sub-commands not propagating

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Paulo Ragonha · committed by zhiyelee · parent d48cda9 · Browse files · 1 file+2 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−0 removed

  • other:+2 added−0 removed

1 file+2 added−0 removed

modified:index.js+2 added
479 unmodified lines
480 args.unshift(local);481 proc = spawn(process.execPath, args, { stdio: 'inherit'});482 }483484 proc.on('close', process.exit.bind(process));485 proc.on('error', function(err) {486 if (err.code == "ENOENT") {487 console.error('\n %s(1) does not exist, try --help\n', bin);488 } else if (err.code == "EACCES") {489 console.error('\n %s(1) not executable. try chmod or run with root\n', bin);490 }491 process.exit(1);492 });493494 this.runningCommand = proc;495};
541 unmodified lines