make exit code logging more robust

pull/284/head
nightwing 2016-03-22 01:11:56 +04:00
rodzic b1caa2fbf6
commit 92a7b39300
1 zmienionych plików z 5 dodań i 3 usunięć

8
node_modules/vfs-local/localfs.js wygenerowano vendored
Wyświetl plik

@ -1827,9 +1827,11 @@ module.exports = function setup(fsOptions) {
}
else if (options.command) {
args.push(BASH + " -l -c '"
+ options.command.replace(/'/g, "'\\''")
+ '; printf "\\e[01;30m\\n\\nProcess exited with code: $?\\e[0m\\n"'
+ "; sleep 0.1;'");
+ (
'trap \'printf "\\e[01;30m\\n\\nProcess exited with code: $?\\e[0m\\n"\' EXIT\n'
+ options.command
).replace(/'/g, "'\\''")
+ "'");
}
args.push(