Class: SproutPunk::CLI

Inherits:
SproutPunk::Commands::Base show all
Defined in:
lib/sproutpunk/cli.rb

Instance Method Summary collapse

Methods inherited from SproutPunk::Commands::Base

command_set, #initialize

Methods included from Helpers

#_config

Constructor Details

This class inherits a constructor from SproutPunk::Commands::Base

Instance Method Details

#setupObject



31
32
# File 'lib/sproutpunk/cli.rb', line 31

def setup
end

#start(*envs) ⇒ Object



11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'lib/sproutpunk/cli.rb', line 11

def start(*envs)
  envs.each do |name|
    src = _config.builds.send(name)
    if src
      say "starting #{name}", :green
      mxmlc "bin/#{name}.swf" do |t|
        t.source_path << "lib"
        t.input = src
      end

      flashplayer :run => "bin/#{name}.swf"

      system "bundle exec rake run"
      #Rake.application["bin/#{name}.swf"].invoke
    end
  end
  exit
end