Sha256: 512ab31f0b1a41aa8a1b2c4b04ac4d5ce6b1b7f83d86b81ba0afea9acb7fee87

Contents?: true

Size: 495 Bytes

Versions: 3

Compression:

Stored size: 495 Bytes

Contents

module HackBoxen
  namespace :hb do

    desc "Copy an endpoint.rb file to the output code directory if the endpoint exists"
    task :endpoint => ['hb:create_required_paths'] do
      endpoints = Dir[File.join(path_to(:hb_engine), '**/*_endpoint.rb')]
      endpoints.each do |srcfile|
        HackBoxen.current_fs.mkpath path_to(:code_dir)
        destfile = File.join(path_to(:code_dir), File.basename(srcfile))
        HackBoxen.current_fs.cp(srcfile, destfile)
      end
    end

  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
hackboxen-0.1.5 lib/hackboxen/tasks/endpoint.rb
hackboxen-0.1.4 lib/hackboxen/tasks/endpoint.rb
hackboxen-0.1.3 lib/hackboxen/tasks/endpoint.rb