tools: enable whitespace related rules in eslint
authorRoman Reiss <me@silverwind.io>
Sat, 13 Jun 2015 19:33:46 +0000 (21:33 +0200)
committerRoman Reiss <me@silverwind.io>
Mon, 15 Jun 2015 14:42:01 +0000 (16:42 +0200)
Enables rules for trailing whitespace, final newline and maximum
consecutive empty lines.

PR-URL: https://github.com/nodejs/io.js/pull/1971
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
.eslintrc

index 7b2b151..9ff3f48 100644 (file)
--- a/.eslintrc
+++ b/.eslintrc
@@ -59,6 +59,12 @@ rules:
   new-parens: 2
   ## max 80 length
   max-len: [2, 80, 2]
+  ## max 2 consecutive empty lines
+  no-multiple-empty-lines: [2, {max: 2}]
+  ## require newline at end of files
+  eol-last: 2
+  ## no trailing spaces
+  no-trailing-spaces: 2
 
   # Strict Mode
   # list: https://github.com/eslint/eslint/tree/master/docs/rules#strict-mode