Class: Malvolio::Generators::CreateGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Malvolio::Generators::CreateGenerator
- Defined in:
- lib/generators/malvolio/create_generator.rb
Instance Method Summary collapse
- #create_config_file ⇒ Object
- #create_css_file ⇒ Object
- #create_dist_and_tmp_dirs ⇒ Object
- #create_html_file ⇒ Object
Instance Method Details
#create_config_file ⇒ Object
17 18 19 |
# File 'lib/generators/malvolio/create_generator.rb', line 17 def create_config_file template "config.yaml", File.join(project_name, "config.yaml") end |
#create_css_file ⇒ Object
13 14 15 |
# File 'lib/generators/malvolio/create_generator.rb', line 13 def create_css_file template "index.scss", File.join(project_name, "src", "scss", "index.scss") end |
#create_dist_and_tmp_dirs ⇒ Object
21 22 23 24 |
# File 'lib/generators/malvolio/create_generator.rb', line 21 def create_dist_and_tmp_dirs Dir.mkdir File.join(project_name, "dist") Dir.mkdir File.join(project_name, "tmp") end |
#create_html_file ⇒ Object
9 10 11 |
# File 'lib/generators/malvolio/create_generator.rb', line 9 def create_html_file template "index.html", File.join(project_name, "src", "index.html") end |