Class: Homura::InstallGenerator

Inherits:
Rails::Generators::Base
  • Object
show all
Defined in:
lib/generators/homura/install/install_generator.rb

Instance Method Summary collapse

Instance Method Details

#app_nameObject



14
15
16
# File 'lib/generators/homura/install/install_generator.rb', line 14

def app_name
  Rails.root.split.last.to_s.titleize
end

#copy_layout_fileObject



9
10
11
12
# File 'lib/generators/homura/install/install_generator.rb', line 9

def copy_layout_file
  copy_file 'application.html.slim',
            'app/views/layouts/application.html.slim'
end

#copy_locale_fileObject



5
6
7
# File 'lib/generators/homura/install/install_generator.rb', line 5

def copy_locale_file
  template 'layout.en.yml.erb', 'config/locales/layout.en.yml'
end