Class: Codeguard::Setup

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/codeguard/setup.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(lint) ⇒ Setup

Returns a new instance of Setup.



11
12
13
# File 'lib/codeguard/setup.rb', line 11

def initialize(lint)
  @lint = lint
end

Instance Attribute Details

#lintObject

Returns the value of attribute lint.



5
6
7
# File 'lib/codeguard/setup.rb', line 5

def lint
  @lint
end

Class Method Details

.perform(lint) ⇒ Object



7
8
9
# File 'lib/codeguard/setup.rb', line 7

def self.perform(lint)
  new(lint).tap(&:perform)
end

Instance Method Details

#performObject



15
16
17
18
# File 'lib/codeguard/setup.rb', line 15

def perform
  lint.setup
  puts Rainbow("Setup for #{lint} was finished.").green
end