Only run ember-template-lint precommit on staged files

Only run ember-template-lint precommit on staged files

  • instead of running on the whole app folder, which just adds extra overhead
diff --git a/lefthook.yml b/lefthook.yml
index 7060a97..749f080 100644
--- a/lefthook.yml
+++ b/lefthook.yml
@@ -17,7 +17,7 @@ pre-commit:
       exclude: "vendor/*|fixtures|public/javascripts|shims.js|ember-addons|template-lintrc|locale/*|test_helper|run-qunit"
       run: yarn eslint -f compact {staged_files}
     ember-template-lint:
-      run: yarn run ember-template-lint app
+      run: yarn run ember-template-lint {staged_files}
     yaml-syntax:
       glob: "*.{yaml,yml}"
       # database.yml is an erb file not a yaml file

GitHub sha: 72a3f387

1 Like