Permalink
Browse files

Add pug-lint support.

  • Loading branch information...
1 parent 890ea42 commit 8f516e57fbfd88598eff3cb9cc0d7c868d37460c @XhmikosR XhmikosR committed Dec 13, 2016
Showing with 46 additions and 1 deletion.
  1. +35 −0 .pug-lintrc.json
  2. +10 −1 make.js
  3. +1 −0 package.json
View
@@ -0,0 +1,35 @@
+{
+ "excludeFiles": ["node_modules/**", "public/**"],
+ "disallowAttributeInterpolation": true,
+ "disallowBlockExpansion": true,
+ "disallowClassAttributeWithStaticValue": true,
+ "disallowDuplicateAttributes": true,
+ "disallowHtmlText": true,
+ "disallowIdAttributeWithStaticValue": true,
+ "disallowLegacyMixinCall": true,
+ "disallowMultipleLineBreaks": true,
+ "disallowSpaceAfterCodeOperator": [
+ "!=",
+ "="
+ ],
+ "disallowSpacesInsideAttributeBrackets": true,
+ "requireClassLiterals": true,
+ "requireClassLiteralsBeforeAttributes": true,
+ "requireLineFeedAtFileEnd": true,
+ "requireLowerCaseAttributes": true,
+ "requireLowerCaseTags": true,
+ "requireSpecificAttributes": [
+ {
+ "img": [
+ "alt"
+ ]
+ }
+ ],
+ "requireStrictEqualityOperators": true,
+ "validateAttributeQuoteMarks": "'",
+ "validateDivTags": true,
+ "validateIndentation": 4,
+ "validateLineBreaks": "LF",
+ "validateSelfClosingTags": true,
+ "validateTemplateString": true
+}
View
@@ -12,6 +12,7 @@ var async = require('async');
var MOCHA = path.join(__dirname, 'node_modules/.bin/mocha');
var ESLINT = path.join(__dirname, 'node_modules/.bin/eslint');
var BOOTLINT = path.join(__dirname, 'node_modules/.bin/bootlint');
+var PUGLINT = path.join(__dirname, 'node_modules/.bin/pug-lint');
var FOREVER = path.join(__dirname, 'node_modules/.bin/forever');
var MOCHA_OPTS = ' --timeout 15000 --slow 500';
@@ -42,8 +43,14 @@ target.eslint = function () {
assertExec(ESLINT + ' lib public/assets/js/ routes scripts tests *.js');
};
+target.puglint = function () {
+ echo('+ puglint .');
+ assertExec(PUGLINT + ' .');
+};
+
target.lint = function () {
target.eslint();
+ target.puglint();
target.bootlint();
};
@@ -186,8 +193,10 @@ target.help = function () {
echo(' run runs for development mode');
echo(' lint lint all the things');
echo(' eslint run eslint');
- echo(' bootlint run Bootlint locally');
+ echo(' bootlint run Bootlint');
+ echo(' puglint run pug-lint');
echo(' travis run Travis CI checks');
+ echo(' appveyor run AppVeyor CI checks');
echo(' help shows this help message');
};
View
@@ -34,6 +34,7 @@
"html-validator": "^2.0.3",
"htmlencode": "^0.0.4",
"mocha": "^3.1.2",
+ "pug-lint": "^2.3.0",
"request": "^2.76.0",
"uglify-js": "^2.7.4"
},

0 comments on commit 8f516e5

Please sign in to comment.