Class: ThemeJuice::Command

Inherits:
Task
  • Object
show all
Defined in:
lib/theme-juice/command.rb

Instance Attribute Summary

Attributes inherited from Task

#tasks

Instance Method Summary collapse

Methods inherited from Task

#runner

Constructor Details

#initialize(opts = {}) ⇒ Command

Returns a new instance of Command.



6
7
8
9
10
# File 'lib/theme-juice/command.rb', line 6

def initialize(opts = {})
  super

  @list = Tasks::List.new
end

Instance Method Details

#executeObject



12
13
14
# File 'lib/theme-juice/command.rb', line 12

def execute
  @tasks.each { |task| task.execute }
end

#unexecuteObject



16
17
18
# File 'lib/theme-juice/command.rb', line 16

def unexecute
  @tasks.each { |task| task.unexecute }
end