Script.ts: if an uncaught error occurs, set the exit code to one so that the deploy scripts fails. Should prevent cases like #2069 from happening again
This commit is contained in:
parent
a3090c0d60
commit
9c64ef6814
1 changed files with 4 additions and 1 deletions
|
@ -22,7 +22,10 @@ export default abstract class Script {
|
|||
const green = (s) => "\x1b[92m" + s + "\x1b[0m"
|
||||
console.log(green("All done! (" + millisNeeded + " ms)"))
|
||||
})
|
||||
.catch((e) => console.log(`ERROR in script ${process.argv[1]}:`, e))
|
||||
.catch((e) => {
|
||||
console.log(`ERROR in script ${process.argv[1]}:`, e)
|
||||
process.exit(1)
|
||||
})
|
||||
}
|
||||
|
||||
public printHelp() {
|
||||
|
|
Loading…
Reference in a new issue