Class: Gnurr::Linters::EsLinter
- Inherits:
-
Gnurr::Linter
- Object
- Gnurr::Linter
- Gnurr::Linters::EsLinter
- Defined in:
- lib/gnurr/linters/es_linter.rb
Overview
ES/JS Linter
Instance Attribute Summary
Attributes inherited from Gnurr::Linter
Instance Method Summary collapse
Methods inherited from Gnurr::Linter
#execute, #files, #filter_messages, #full_range, #initialize, #line_diffs, #relevant_messages, #violation_count
Methods included from Git
#extract_lines, #file_diffs, #full_file_diff
Methods included from Helper
#array_to_ranges, #escaped_filename, #left_bump, #log_error, #severity_color
Methods included from CLI
Constructor Details
This class inherits a constructor from Gnurr::Linter
Instance Method Details
#color ⇒ Object
11 12 13 |
# File 'lib/gnurr/linters/es_linter.rb', line 11 def color :red end |
#command ⇒ Object
15 16 17 |
# File 'lib/gnurr/linters/es_linter.rb', line 15 def command 'eslint -f json' end |
#filter(file) ⇒ Object
19 20 21 |
# File 'lib/gnurr/linters/es_linter.rb', line 19 def filter(file) File.extname(file) == '.js' end |
#type ⇒ Object
7 8 9 |
# File 'lib/gnurr/linters/es_linter.rb', line 7 def type :es end |