[Pkg-javascript-commits] [pdf.js] 95/141: Introduces .jshintignore

David Prévot taffit at moszumanska.debian.org
Sat Apr 19 22:40:34 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit fcebe57d8e293da5a5d3eaf6df1adfa64f41f3b5
Author: Yury Delendik <ydelendik at mozilla.com>
Date:   Fri Apr 11 11:42:44 2014 -0500

    Introduces .jshintignore
---
 .jshintignore | 17 +++++++++++++++++
 make.js       | 20 +-------------------
 package.json  |  2 +-
 3 files changed, 19 insertions(+), 20 deletions(-)

diff --git a/.jshintignore b/.jshintignore
new file mode 100644
index 0000000..a9f83b3
--- /dev/null
+++ b/.jshintignore
@@ -0,0 +1,17 @@
+build/
+l10n/
+docs/
+node_modules/
+examples/
+external/webL10n/
+external/shelljs/
+external/jpgjs/
+external/jasmine/
+external/cmapscompress/
+external/importL10n/
+test/tmp/
+test/features/
+test/resources/
+test/mozcentral/
+test/font/*_spec.js
+*~/
diff --git a/make.js b/make.js
index 2a0be66..bc2fad2 100644
--- a/make.js
+++ b/make.js
@@ -1267,31 +1267,13 @@ target.lint = function() {
   echo();
   echo('### Linting JS files');
 
-  var LINT_FILES = ['make.js',
-                    'external/builder/',
-                    'external/crlfchecker/',
-                    'src/',
-                    'web/',
-                    'test/downloadutils.js',
-                    'test/driver.js',
-                    'test/test.js',
-                    'test/testutils.js',
-                    'test/webbrowser.js',
-                    'test/webserver.js',
-                    'test/font/fontutils.js',
-                    'test/font/ttxdriver.js',
-                    'test/unit/',
-                    'extensions/firefox/',
-                    'extensions/chromium/'
-                    ];
-
   var jshintPath = path.normalize('./node_modules/.bin/jshint');
   if (!test('-f', jshintPath)) {
     echo('jshint is not installed -- installing...');
     exec('npm install jshint at 2.4.x'); // TODO read version from package.json
   }
 
-  var exitCode = exec('"' + jshintPath + '" ' + LINT_FILES.join(' ')).code;
+  var exitCode = exec('"' + jshintPath + '" .').code;
   if (exitCode === 0) {
     echo('files checked, no errors found');
   }
diff --git a/package.json b/package.json
index 30c9a4f..b50285e 100644
--- a/package.json
+++ b/package.json
@@ -12,7 +12,7 @@
     "typogr": "0.5.x"
   },
   "scripts": {
-    "test": "node make lint"
+    "test": "node ./node_modules/.bin/jshint ."
   },
   "repository": {
     "type": "git",

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list