Class: Tzispa::Command::App

Inherits:
Object
  • Object
show all
Defined in:
lib/tzispa/command/app.rb

Constant Summary collapse

APP_STRUCTURE =
[
  'api',
  'config',
  'config/locales',
  'error',
  'helpers',
  'rig',
  'rig/block',
  'rig/layout',
  'rig/static'
]

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name) ⇒ App

Returns a new instance of App.



27
28
29
# File 'lib/tzispa/command/app.rb', line 27

def initialize(name)
  @domain = Tzispa::Domain.new(name)
end

Instance Attribute Details

#configObject (readonly)

Returns the value of attribute config.



25
26
27
# File 'lib/tzispa/command/app.rb', line 25

def config
  @config
end

#domainObject (readonly)

Returns the value of attribute domain.



25
26
27
# File 'lib/tzispa/command/app.rb', line 25

def domain
  @domain
end

Instance Method Details

#generate(host, mount_path = nil) ⇒ Object



31
32
33
34
35
36
37
# File 'lib/tzispa/command/app.rb', line 31

def generate(host, mount_path=nil)
  update_project
  create_structure
  create_class mount_path
  create_appconfig(host)
  create_home_layout
end