Class: Coppy::Runner

Inherits:
Object
  • Object
show all
Defined in:
lib/coppy/runner.rb

Instance Method Summary collapse

Constructor Details

#initialize(source, target) ⇒ Runner

Returns a new instance of Runner.



6
7
8
9
# File 'lib/coppy/runner.rb', line 6

def initialize(source, target)
  @source = source
  @target = target
end

Instance Method Details

#callObject



11
12
13
14
15
16
17
18
19
# File 'lib/coppy/runner.rb', line 11

def call
  manifesto = load_manifesto
  env = Environment.new(
    source: source,
    target: target,
    app_name: Name.new(target.split(File::Separator).last)
  )
  manifesto.execute!(env)
end