class Lono::AppFile::Registry::Item

Holds metadata about the item in the regsitry.

Attributes

name[R]
options[R]
type[R]

Public Class Methods

new(name, blueprint, options={}) click to toggle source
# File lib/lono/app_file/registry/item.rb, line 7
def initialize(name, blueprint, options={})
  @name, @blueprint, @options = name, blueprint, options
  @type = options[:type] || "file"
end

Public Instance Methods

output_path() click to toggle source
# File lib/lono/app_file/registry/item.rb, line 16
def output_path
  if @type == "file"
    "#{Lono.root}/output/#{@blueprint}/files/#{@name}"
  else
    "#{Lono.root}/output/#{@blueprint}/lambda_layers/#{@name}/opt"
  end
end
src_path() click to toggle source
# File lib/lono/app_file/registry/item.rb, line 12
def src_path
  "#{Lono.blueprint_root}/app/files/#{@name}"
end