Skip to content

Commit

Permalink
Add jshint config and lint script.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kami committed Jun 6, 2013
1 parent 898daf8 commit 9895dd9
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 0 deletions.
18 changes: 18 additions & 0 deletions jshint.json
@@ -0,0 +1,18 @@
{
"maxerr" : 100,
"node" : true,
"curly" : true,
"eqeqeq" : true,
"latedef" : false,
"undef" : true,
"newcap" : true,
"nonew" : true,
"onevar" : false,
"trailing" : true,
"white" : false,
"sub" : true,
"evil" : true,
"es5" : true,
"onecase" : true,
"strict" : false
}
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -41,6 +41,7 @@
"bin": "./bin"
},
"scripts": {
"lint": "./scripts/lint.sh",
"test": "make test"
},
"dependencies": {
Expand Down
18 changes: 18 additions & 0 deletions scripts/lint.sh
@@ -0,0 +1,18 @@
#!/bin/bash
#
# Copyright 2013 Tomaz Muraus
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#

./node_modules/.bin/jshint $(find ./lib -type f -name "*.js" | grep -v lib/extern) --config jshint.json

0 comments on commit 9895dd9

Please sign in to comment.