Class: RuboCop::CLI::Command::ShowDocsUrl Private

Inherits:
Base
  • Object
show all
Defined in:
lib/rubocop/cli/command/show_docs_url.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Prints out url to documentation of provided cops or documentation base url by default.

Instance Attribute Summary

Attributes inherited from Base

#env

Instance Method Summary collapse

Methods inherited from Base

by_command_name, inherited

Constructor Details

#initialize(env) ⇒ ShowDocsUrl

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of ShowDocsUrl.



12
13
14
15
16
# File 'lib/rubocop/cli/command/show_docs_url.rb', line 12

def initialize(env)
  super

  @config = @config_store.for(Dir.pwd)
end

Instance Method Details

#runObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



18
19
20
# File 'lib/rubocop/cli/command/show_docs_url.rb', line 18

def run
  print_documentation_url
end