gulp-my-tasks: jscs rules and gulp plugin
authorgustavo <gu.martinm@gmail.com>
Sun, 15 Nov 2015 22:46:43 +0000 (23:46 +0100)
committergustavo <gu.martinm@gmail.com>
Sun, 15 Nov 2015 22:46:43 +0000 (23:46 +0100)
gulp/gulp-my-tasks/package.json
gulp/gulp-my-tasks/tasks/.jscsrc
gulp/gulp-my-tasks/tasks/tasks.js

index e76424a..3aabd62 100644 (file)
@@ -25,6 +25,7 @@
     "gulp-if": "~2.0.0",
     "gulp-inject": "~3.0.0",
     "gulp-jscs": "~3.0.2",
+    "gulp-jscs-stylish" : "~1.2.1",
     "gulp-jshint": "~1.12.0",
     "gulp-load-plugins": "~1.1.0",
     "gulp-minify-css": "~1.2.1",
index be714a3..96b02d5 100644 (file)
 
   "disallowMultipleLineBreaks": true,
 
-  "disallowCommaBeforeLineBreak": null,
-  "disallowDanglingUnderscores": null,
-  "disallowEmptyBlocks": null,
-  "disallowTrailingComma": null,
-  "requireCommaBeforeLineBreak": null,
-  "requireDotNotation": null,
-  "requireMultipleVarDecl": null,
+  "disallowCommaBeforeLineBreak": false,
+  "disallowDanglingUnderscores": false,
+  "disallowEmptyBlocks": true,
+  "disallowTrailingComma": true,
+  "requireCommaBeforeLineBreak": true,
+  "requireDotNotation": true,
+  "requireMultipleVarDecl": false,
   "requireParenthesesAroundIIFE": true
 }
index 82a99d8..cafeb80 100644 (file)
@@ -56,12 +56,13 @@ module.exports = function(gulp, customConfig) {
         return "vet-js: " + filepath;
       })))
       .pipe(plugins.jshint(config.jsHintConfigurationFile))
-      .pipe(plugins.jshint.reporter('jshint-stylish', {verbose: true}))
-      .pipe(plugins.jshint.reporter('fail'))
       .pipe(plugins.jscs({
         configPath: config.jscsConfigurationFile,
         fix: false
-      }));
+      }))
+      .pipe(plugins.jscsStylish.combineWithHintResults())
+      .pipe(plugins.jshint.reporter('jshint-stylish', {verbose: true}))
+      .pipe(plugins.jshint.reporter('fail'));
   });
 
   /**