Class: CC::CLI::Engines::List

Inherits:
EngineCommand show all
Defined in:
lib/cc/cli/engines/list.rb

Constant Summary collapse

SHORT_HELP =
"List all available engines".freeze

Constants included from Analyzer

Analyzer::UnreadableFileError

Constants inherited from Command

Command::CODECLIMATE_YAML, Command::NAMESPACE

Instance Method Summary collapse

Methods inherited from Command

[], abstract!, abstract?, all, command_name, #execute, help, inherited, #initialize, #require_codeclimate_yml, short_help, synopsis

Methods included from Output

#colorize, #fatal, #rainbow, #say, #success, #terminal, #warn

Constructor Details

This class inherits a constructor from CC::CLI::Command

Instance Method Details

#runObject



7
8
9
10
11
12
# File 'lib/cc/cli/engines/list.rb', line 7

def run
  say "Available engines:"
  engine_registry_list.sort_by { |name, _| name }.each do |name, attributes|
    say "- #{name}: #{attributes["description"]}"
  end
end