Class: Rusky::Task

Inherits:
Object
  • Object
show all
Defined in:
lib/rusky/task.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(base = nil) ⇒ Task

Returns a new instance of Task.



14
15
16
# File 'lib/rusky/task.rb', line 14

def initialize(base=nil)
  @cwd = base || Rusky.current_work_directory_name
end

Class Method Details

.install(base = nil) ⇒ Object



9
10
11
# File 'lib/rusky/task.rb', line 9

def install(base=nil)
  new(base).install
end

Instance Method Details

#installObject



18
19
20
21
# File 'lib/rusky/task.rb', line 18

def install
  setting = Rusky::Setting.new(@cwd)
  Rusky::Hooks.new(@cwd, setting).define_tasks
end