Class: RuboCop::RbsInline::Plugin
- Inherits:
-
LintRoller::Plugin
- Object
- LintRoller::Plugin
- RuboCop::RbsInline::Plugin
- Defined in:
- lib/rubocop/rbs_inline/plugin.rb
Overview
A plugin that integrates RuboCop RBS Inline with RuboCop’s plugin system.
Instance Method Summary collapse
Instance Method Details
#about ⇒ Object
9 10 11 12 13 14 15 16 17 |
# File 'lib/rubocop/rbs_inline/plugin.rb', line 9 def about LintRoller::About.new( name: 'rubocop-rbs_inline', version: RuboCop::RbsInline::VERSION, homepage: 'https://github.com/tk0miya/rubocop-rbs_inline', description: 'rubocop-rbs_inline is a RuboCop extension that checks for RBS::Inline annotation comments ' \ 'in Ruby code.' ) end |
#rules(_context) ⇒ Object
23 24 25 26 27 |
# File 'lib/rubocop/rbs_inline/plugin.rb', line 23 def rules(_context) project_root = Pathname.new(__dir__).join('../../../') # steep:ignore LintRoller::Rules.new(type: :path, config_format: :rubocop, value: project_root.join('config', 'default.yml')) end |
#supported?(context) ⇒ Boolean
19 20 21 |
# File 'lib/rubocop/rbs_inline/plugin.rb', line 19 def supported?(context) context.engine == :rubocop end |