Class: Lono::Template

Inherits:
Command show all
Defined in:
lib/lono/template/context.rb,
lib/lono/template.rb,
lib/lono/template/dsl.rb,
lib/lono/template/erb.rb,
lib/lono/template/base.rb,
lib/lono/template/util.rb,
lib/lono/template/upload.rb,
lib/lono/template/evaluate.rb,
lib/lono/template/generator.rb,
lib/lono/template/post_processor.rb

Overview

Encapsulates helper methods and instance variables to be rendered in the ERB templates.

Defined Under Namespace

Modules: AwsService, Evaluate, Helper, Util Classes: Base, Bashify, Context, Dsl, Erb, Generator, PostProcessor, Template, Upload

Instance Method Summary collapse

Methods inherited from Command

alter_command_description, command_help, dispatch, website

Instance Method Details

#bashify(path) ⇒ Object



22
23
24
# File 'lib/lono/template.rb', line 22

def bashify(path)
  Bashify.new(path: path).run
end

#generate(blueprint = nil) ⇒ Object



9
10
11
12
13
# File 'lib/lono/template.rb', line 9

def generate(blueprint=nil)
  Blueprint::Find.one_or_all(blueprint).each do |b|
    Generator.new(b, options).run
  end
end

#upload(blueprint) ⇒ Object



16
17
18
# File 'lib/lono/template.rb', line 16

def upload(blueprint)
  Upload.new(blueprint, options.clone).run
end