Sha256: 64230ed3a6b957d9645e95573bc4a41763b241dedadcb72d4cea9c496c72b8e4

Contents?: true

Size: 798 Bytes

Versions: 7

Compression:

Stored size: 798 Bytes

Contents

module Spontaneous
  module Cli
    class Assets < ::Thor
      include Spontaneous::Cli::TaskUtils

      namespace :assets
      default_task :compile


      desc "compile", "Compiles assets for the Spontaneous UI"

      method_option :destination, :type => :string, :aliases => "-d", :required => true, :desc => "Compile assets into DESTINATION"

      def compile
        prepare(:compile)
        # options[:mode] = :console
        # Find path to install of Spontaneous using bundler and then
        # use this path as params to compiler
        spec = Bundler.load.specs.find{|s| s.name == "spontaneous" }
        p spec.full_gem_path

        compiler = ::Spontaneous::Asset::AppCompiler.new(spec.full_gem_path, options.destination)
        compiler.compile
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
spontaneous-0.2.0.beta4 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.beta3 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.beta2 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.beta1 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.alpha7 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.alpha6 lib/spontaneous/cli/assets.rb
spontaneous-0.2.0.alpha5 lib/spontaneous/cli/assets.rb