Class: Steep::RakeTask

Inherits:
Rake::TaskLib
  • Object
show all
Defined in:
lib/steep/rake_task.rb

Overview

Provides Rake tasks for running Steep commands.

require “steep/rake_task” Steep::RakeTask.new do |t|

t.check.severity_level = :error
t.watch.verbose
t.stats << "--format=table"

end

Defined Under Namespace

Classes: CommandConfiguration, TaskConfiguration

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name = :steep, cli_runner = default_cli_runner) {|configuration| ... } ⇒ RakeTask

Returns a new instance of RakeTask.

Yields:

  • (configuration)


21
22
23
24
25
26
27
28
29
30
31
# File 'lib/steep/rake_task.rb', line 21

def initialize(name = :steep, cli_runner = default_cli_runner)
  super()

  @name = name

  configuration = TaskConfiguration.new

  yield configuration if block_given?

  define_tasks(configuration, cli_runner)
end

Instance Attribute Details

#nameObject

steep:ignore UnknownConstant



15
16
17
# File 'lib/steep/rake_task.rb', line 15

def name
  @name
end

Class Method Details

.available_commandsObject



17
18
19
# File 'lib/steep/rake_task.rb', line 17

def self.available_commands
  %i(init check stats binstub project watch)
end