diff --git a/fabpolish/contrib.py b/fabpolish/contrib.py index 90f25a4..63788be 100644 --- a/fabpolish/contrib.py +++ b/fabpolish/contrib.py @@ -129,3 +129,13 @@ def check_image_edited(): def composer_validate(): info('Running composer validate...') return local('composer validate') + + +@sniff(severity='major', timing='fast') +def run_eslint(): + info('Running ESLint...') + return local( + "git ls-files | " + "grep '\.js$' | " + "xargs ./node_modules/eslint/bin/eslint.js" + )