replace eslint with standard
This commit is contained in:
parent
6f845373a7
commit
e156faea5c
4 changed files with 1 additions and 80 deletions
|
@ -29,7 +29,7 @@
|
|||
"scripts": {
|
||||
"bootstrap": "python ./script/bootstrap.py",
|
||||
"build": "python ./script/build.py -c D",
|
||||
"lint": "python ./script/eslint.py && python ./script/cpplint.py",
|
||||
"lint": "standard && python ./script/cpplint.py",
|
||||
"preinstall": "node -e 'process.exit(0)'",
|
||||
"repl": "python ./script/start.py --interactive",
|
||||
"start": "python ./script/start.py",
|
||||
|
|
|
@ -1,36 +0,0 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import glob
|
||||
import os
|
||||
import sys
|
||||
|
||||
from lib.config import PLATFORM
|
||||
from lib.util import execute
|
||||
|
||||
|
||||
SOURCE_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
|
||||
|
||||
|
||||
def main():
|
||||
os.chdir(SOURCE_ROOT)
|
||||
|
||||
# Skip eslint on our Windows build machine for now.
|
||||
if PLATFORM == 'win32' and os.getenv('JANKY_SHA1'):
|
||||
return
|
||||
|
||||
eslint = os.path.join(SOURCE_ROOT, 'node_modules', '.bin', 'eslint')
|
||||
if sys.platform in ['win32', 'cygwin']:
|
||||
eslint += '.cmd'
|
||||
settings = ['--quiet', '--config']
|
||||
|
||||
sourceConfig = os.path.join('script', 'eslintrc-base.json')
|
||||
sourceFiles = ['lib']
|
||||
execute([eslint] + settings + [sourceConfig] + sourceFiles)
|
||||
|
||||
specConfig = os.path.join('script', 'eslintrc-spec.json')
|
||||
specFiles = glob.glob('spec/*.js')
|
||||
execute([eslint] + settings + [specConfig] + specFiles)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
sys.exit(main())
|
|
@ -1,36 +0,0 @@
|
|||
{
|
||||
"rules": {
|
||||
"indent": [
|
||||
2,
|
||||
2,
|
||||
{
|
||||
"SwitchCase": 1
|
||||
}
|
||||
],
|
||||
"quotes": [
|
||||
0,
|
||||
"single"
|
||||
],
|
||||
"semi": [
|
||||
2,
|
||||
"always"
|
||||
],
|
||||
"comma-dangle": 0,
|
||||
"linebreak-style": 0,
|
||||
"no-console": 0,
|
||||
"no-undef": 2,
|
||||
"no-unused-vars": 2
|
||||
},
|
||||
"env": {
|
||||
"es6": true,
|
||||
"node": true,
|
||||
"browser": true
|
||||
},
|
||||
"extends": "eslint:recommended",
|
||||
"globals": {
|
||||
"DevToolsAPI": false,
|
||||
"InspectorFrontendHost": false,
|
||||
"WebInspector": false,
|
||||
"WebView": false
|
||||
}
|
||||
}
|
|
@ -1,7 +0,0 @@
|
|||
{
|
||||
"env": {
|
||||
"jquery": true,
|
||||
"mocha": true
|
||||
},
|
||||
"extends": "./eslintrc-base.json"
|
||||
}
|
Loading…
Reference in a new issue