Class: SlimLint::Runner
- Inherits:
-
Object
- Object
- SlimLint::Runner
- Defined in:
- lib/slim_lint/runner.rb
Overview
Responsible for running the applicable linters against the desired files.
Instance Method Summary collapse
-
#run(options = {}) ⇒ SlimLint::Report
Runs the appropriate linters against the desired files given the specified options.
Instance Method Details
#run(options = {}) ⇒ SlimLint::Report
Runs the appropriate linters against the desired files given the specified options.
16 17 18 19 20 21 22 23 24 25 26 27 |
# File 'lib/slim_lint/runner.rb', line 16 def run( = {}) config = load_applicable_config() files = extract_applicable_files(config, ) linter_selector = SlimLint::LinterSelector.new(config, ) lints = files.map do |file| collect_lints(file, linter_selector, config) end.flatten SlimLint::Report.new(lints, files) end |