Repository: ignite Updated Branches: refs/heads/ignite-843-rc2 8da02627f -> 8d0f2b04b
http://git-wip-us.apache.org/repos/asf/ignite/blob/6b110a8d/modules/control-center-web/src/main/js/gulpfile.js/tasks/eslint.js ---------------------------------------------------------------------- diff --git a/modules/control-center-web/src/main/js/gulpfile.js/tasks/eslint.js b/modules/control-center-web/src/main/js/gulpfile.js/tasks/eslint.js new file mode 100644 index 0000000..e1db55f --- /dev/null +++ b/modules/control-center-web/src/main/js/gulpfile.js/tasks/eslint.js @@ -0,0 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You 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. + */ + +var gulp = require('gulp'); +var eslint = require('gulp-eslint'); + +var paths = [ + './app/**/*.js' +]; + +gulp.task('eslint', function() { + return gulp.src(paths) + .pipe(eslint()) + .pipe(eslint.format()); +}) \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/6b110a8d/modules/control-center-web/src/main/js/package.json ---------------------------------------------------------------------- diff --git a/modules/control-center-web/src/main/js/package.json b/modules/control-center-web/src/main/js/package.json index 77b9e06..2918fa7 100644 --- a/modules/control-center-web/src/main/js/package.json +++ b/modules/control-center-web/src/main/js/package.json @@ -21,6 +21,7 @@ }, "dependencies": { "async": "1.5.0", + "babel-eslint": "^4.1.6", "body-parser": "~1.14.1", "bootstrap-sass": "^3.3.6", "connect-modrewrite": "^0.8.2", @@ -36,6 +37,7 @@ "gulp-concat": "^2.6.0", "gulp-connect": "^2.2.0", "gulp-environments": "^0.1.1", + "gulp-eslint": "^1.1.1", "gulp-inject": "^3.0.0", "gulp-jade": "^1.1.0", "gulp-rimraf": "^0.2.0",