Class: InterfaceLift::Installer

Inherits:
Object
  • Object
show all
Defined in:
lib/installer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path, theme, catalog_path = InterfaceLift::DEFAULT_CATALOG_PATH) ⇒ Installer

Returns a new instance of Installer.



6
7
8
9
10
11
12
13
# File 'lib/installer.rb', line 6

def initialize(path,theme,catalog_path=InterfaceLift::DEFAULT_CATALOG_PATH)      
  @path = path
  @theme = theme     
  @theme_path =  "#{catalog_path}/#{theme}"      

  raise "Given path does not contain a rails app." unless File.directory? "#{@path}/public" 
  raise "Theme #{@theme} is not available." unless File.directory? @theme_path   
end

Instance Attribute Details

#pathObject (readonly)

Returns the value of attribute path.



3
4
5
# File 'lib/installer.rb', line 3

def path
  @path
end

#themeObject (readonly)

Returns the value of attribute theme.



3
4
5
# File 'lib/installer.rb', line 3

def theme
  @theme
end

#theme_pathObject (readonly)

Returns the value of attribute theme_path.



3
4
5
# File 'lib/installer.rb', line 3

def theme_path
  @theme_path
end

Instance Method Details

#install!Object



15
16
17
18
19
20
21
# File 'lib/installer.rb', line 15

def install!  
  install_images
  install_stylesheets
  install_layouts
  install_javascript
  theme_install
end