Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduces .jshintignore #4602

Merged
merged 1 commit into from
Apr 11, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .jshintignore
Original file line number Diff line number Diff line change
@@ -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
*~/
20 changes: 1 addition & 19 deletions make.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 [email protected]'); // 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');
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"typogr": "0.5.x"
},
"scripts": {
"test": "node make lint"
"test": "node ./node_modules/.bin/jshint ."
},
"repository": {
"type": "git",
Expand Down