Class: RuboCop::OrderedMethods::Plugin
- Inherits:
-
LintRoller::Plugin
- Object
- LintRoller::Plugin
- RuboCop::OrderedMethods::Plugin
- Defined in:
- lib/rubocop/ordered_methods/plugin.rb
Overview
Official plugin system for Rubocop
Instance Method Summary collapse
Instance Method Details
#about ⇒ Object
10 11 12 13 14 15 16 17 |
# File 'lib/rubocop/ordered_methods/plugin.rb', line 10 def about LintRoller::About.new( name: 'rubocop-ordered_methods', version: RuboCop::OrderedMethods::VERSION, homepage: 'https://github.com/shanecav84/rubocop-ordered_methods', description: 'Check that methods are defined alphabetically per access modifier block.' ) end |
#rules(_context) ⇒ Object
19 20 21 22 23 24 25 |
# File 'lib/rubocop/ordered_methods/plugin.rb', line 19 def rules(_context) LintRoller::Rules.new( type: :path, config_format: :rubocop, value: Pathname.new(__dir__).join('../../../config/default.yml') ) end |
#supported?(context) ⇒ Boolean
27 28 29 |
# File 'lib/rubocop/ordered_methods/plugin.rb', line 27 def supported?(context) context.engine == :rubocop end |