Method: PreCommit::Checks::ScssLint#call
- Defined in:
- lib/plugins/pre_commit/checks/scss_lint.rb
permalink #call(staged_files) ⇒ Object
[View source]
7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/plugins/pre_commit/checks/scss_lint.rb', line 7 def call(staged_files) staged_files = staged_files.grep(/\.scss$/) return if staged_files.empty? result = in_groups(staged_files).map do |files| args = %w{scss-lint} + config_file_flag + files execute(args) end.compact result.empty? ? nil : result.join("\n") end |