exit code 1 in case of failed builds (#3535)

Fixes https://github.com/nuxt/nuxt.js/issues/3534
This commit is contained in:
Dmitry Molotkov 2018-07-20 18:12:29 +03:00 committed by Clark Du
parent dfef5252de
commit b0d2f674c8

View File

@ -525,6 +525,10 @@ export default class Builder {
if (this.options.test) { if (this.options.test) {
err = stats.toString(this.options.build.stats) err = stats.toString(this.options.build.stats)
} }
if (!err) {
// actual errors will be printed by webpack itself
err = 'Nuxt Build Error'
}
return reject(err) return reject(err)
} }