lib/haml_lint/runner.rb
def run(options = {})
      config = load_applicable_config(options)
      files = extract_applicable_files(options)
      linters = extract_enabled_linters(config, options)

      raise HamlLint::Exceptions::NoLintersError, 'No linters specified' if linters.empty?

      @lints = []
      files.each do |file|
        find_lints(file, linters, config)
      end

      linters.each do |linter|
        @lints += linter.lints
      end

      HamlLint::Report.new(@lints)
    end
# Runs the appropriate linters against the desired files given the specified
# options.
#
# @param options [Hash]
# @raise [HamlLint::Exceptions::NoLintersError] when no linters are enabled
# @return [HamlLint::Report] a summary of all lints found
Runs the appropriate linters against the desired files given the specified
options.
Runs the appropriate linters against the desired files given the specified options .
def run(options = {})
      config = load_applicable_config(options)
      files = extract_applicable_files(options)
      linters = extract_enabled_linters(config, options)
      raise HamlLint::Exceptions::NoLintersError, 'No linters specified' if linters.empty?
      @lints = []
      files.each do |file|
        find_lints(file, linters, config)
      end
      linters.each do |linter|
        @lints += linter.lints
      end
      HamlLint::Report.new(@lints)
    end
def run ( options = { } ) config = load_applicable_config ( options ) files = extract_applicable_files ( options ) linters = extract_enabled_linters ( config , options ) raise HamlLint :: Exceptions :: NoLintersError , 'No linters specified' if linters . empty? @lints = [ ] files . each do | file | find_lints ( file , linters , config ) end linters . each do | linter | @lints += linter . lints end HamlLint :: Report . new ( @lints ) end
Runs the appropriate linters against the desired files given the specified
options.
Runs the appropriate linters against the desired files given the specified options .
a summary of all lints found
a summary of all lints found
HamlLint::Report
[HamlLint::Exceptions::NoLintersError] when no linters are enabled
[ HamlLint :: Exceptions :: NoLintersError ] when no linters are enabled
options
None