Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/grunt-bootlint.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tasks
diff options
context:
space:
mode:
authorZac Echola <zac.echola@so.mnscu.edu>2014-07-28 18:50:04 +0400
committerZac Echola <zac.echola@so.mnscu.edu>2014-07-28 18:50:04 +0400
commit2ba8e4e73f54d804522723e15b756fa3e98bd78b (patch)
tree06a91d89935226a6ca9586ba70a72ca5540a3ca8 /tasks
parentff2d7efc506c0e8ba2b2f4df907d617d8ff36ccd (diff)
Simple stop on error
Closes #1
Diffstat (limited to 'tasks')
-rw-r--r--tasks/bootlint.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/tasks/bootlint.js b/tasks/bootlint.js
index 3bb6e5a..fc400e7 100644
--- a/tasks/bootlint.js
+++ b/tasks/bootlint.js
@@ -30,7 +30,7 @@ module.exports = function(grunt) {
grunt.registerMultiTask('bootlint', 'An HTML linter for Bootstrap projects', function() {
var options = this.options({
- stoponerror: true // not implemented yet...
+ stoponerror: false
});
// Iterate over all specified file groups.
@@ -52,7 +52,11 @@ module.exports = function(grunt) {
totalErrCount += errs.length;
errs.forEach(function (msg) {
- grunt.log.warn(filepath + ':', msg.error);
+ if (options.stoponerror) {
+ grunt.fail.warn(filepath + ':' + msg.error);
+ } else {
+ grunt.log.warn(filepath + ':', msg.error);
+ }
});
});