Sha256: 7dc99d50efa50678a8a9f631686f53dc5edce4f373426d007c252cafe55f048b

Contents?: true

Size: 849 Bytes

Versions: 11

Compression:

Stored size: 849 Bytes

Contents

require 'fileutils'
module HighFive
  module InitTask
    def self.included(mod) 
      mod.class_eval do

        desc "init", "Initialize the high_five configuration in the current working directory"
        def init
          self.destination_root = Dir.pwd
          self.source_paths << HighFive::TEMPLATE_PATH

          inside "config" do
            template("high_five.rb")
            inside "high_five" do
              copy_file "index.html.erb", :skip => true
              copy_file "app-common.js", :skip => true

              #TODO make this a CLI argument
              platforms = ["android", "ios"]
              platforms.each do |platform|
                copy_file "app-platform.js", "app-#{platform}.js", :skip => true
              end
            end
          end
        end


      end #end class_eval
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
high_five-0.1.5 lib/high_five/init_task.rb
high_five-0.1.4 lib/high_five/init_task.rb
high_five-0.1.3 lib/high_five/init_task.rb
high_five-0.1.2 lib/high_five/init_task.rb
high_five-0.1.1 lib/high_five/init_task.rb
high_five-0.1.0 lib/high_five/init_task.rb
high_five-0.0.8 lib/high_five/init_task.rb
high_five-0.0.7 lib/high_five/init_task.rb
high_five-0.0.6 lib/high_five/init_task.rb
high_five-0.0.5 lib/high_five/init_task.rb
high_five-0.0.4 lib/high_five/init_task.rb