Skip to content

Commit 3e85ccb

Browse files
committed
fix(build): show full error stats
1 parent de0329a commit 3e85ccb

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

packages/angular-cli/tasks/build-webpack.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,6 @@ export default <any>Task.extend({
2626
runTaskOptions.aot
2727
).config;
2828

29-
// fail on build error
30-
config.bail = true;
31-
3229
const webpackCompiler: any = webpack(config);
3330

3431
const ProgressPlugin = require('webpack/lib/ProgressPlugin');
@@ -43,17 +40,12 @@ export default <any>Task.extend({
4340
// TODO: Make conditional if using --watch
4441
webpackCompiler.purgeInputFileSystem();
4542

46-
if (err) {
47-
lastHash = null;
48-
console.error(err.details || err);
49-
reject(err.details || err);
50-
}
51-
5243
if (stats.hash !== lastHash) {
5344
lastHash = stats.hash;
5445
process.stdout.write(stats.toString(webpackOutputOptions) + '\n');
5546
}
56-
resolve();
47+
48+
stats.hasErrors() ? reject() : resolve();
5749
});
5850
});
5951
}

0 commit comments

Comments
 (0)