summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGraeme Yeates <yeatesgraeme@gmail.com>2015-07-03 12:13:12 -0400
committerGraeme Yeates <yeatesgraeme@gmail.com>2015-07-08 20:06:12 -0400
commit9d55efe8002270acbfa6139aa175a00b68ff3e41 (patch)
treea02347eea981d650a6b940f6bae5e36158eef6ae
parentdeaa5a1b8a36eacbb7d31f3a825828f37220396b (diff)
downloadasync-9d55efe8002270acbfa6139aa175a00b68ff3e41.tar.gz
:scroll: Manadate style guide with jscs
:hammer: make lint should use JSCS
-rw-r--r--.jscsrc3
-rw-r--r--Makefile2
-rw-r--r--package.json3
3 files changed, 7 insertions, 1 deletions
diff --git a/.jscsrc b/.jscsrc
new file mode 100644
index 0000000..b8cfa17
--- /dev/null
+++ b/.jscsrc
@@ -0,0 +1,3 @@
+{
+ "validateIndentation": 4
+} \ No newline at end of file
diff --git a/Makefile b/Makefile
index c3cec30..35f4c38 100644
--- a/Makefile
+++ b/Makefile
@@ -3,6 +3,7 @@ CWD := $(shell pwd)
NODEUNIT = "$(CWD)/node_modules/.bin/nodeunit"
UGLIFY = "$(CWD)/node_modules/.bin/uglifyjs"
JSHINT = "$(CWD)/node_modules/.bin/jshint"
+JSCS = "$(CWD)/node_modules/.bin/jscs"
XYZ = node_modules/.bin/xyz --repo git@github.com:caolan/async.git
BUILDDIR = lib
@@ -21,6 +22,7 @@ clean:
lint:
$(JSHINT) lib/*.js test/*.js perf/*.js
+ $(JSCS) lib/*.js test/*.js perf/*.js
.PHONY: test lint build all clean
diff --git a/package.json b/package.json
index e26d3c6..754deb5 100644
--- a/package.json
+++ b/package.json
@@ -21,6 +21,7 @@
"devDependencies": {
"benchmark": "bestiejs/benchmark.js",
"coveralls": "^2.11.2",
+ "jscs": "^1.13.1",
"jshint": "~2.8.0",
"lodash": "^3.9.0",
"mkdirp": "~0.5.1",
@@ -43,7 +44,7 @@
},
"scripts": {
"test": "npm run-script lint && nodeunit test/test-async.js",
- "lint": "jshint lib/*.js test/*.js perf/*.js",
+ "lint": "jshint lib/*.js test/*.js perf/*.js && jscs lib/*.js test/*.js perf/*.js",
"coverage": "nyc npm test && nyc report",
"coveralls": "nyc npm test && nyc report --reporter=text-lcov | coveralls"
},