Class: Modulorails::ModuloprojectGenerator
- Inherits:
-
Generators::Base
- Object
- Rails::Generators::Base
- Generators::Base
- Modulorails::ModuloprojectGenerator
- Defined in:
- lib/generators/modulorails/moduloproject/moduloproject_generator.rb
Instance Method Summary collapse
Methods inherited from Generators::Base
Instance Method Details
#create_config ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/generators/modulorails/moduloproject/moduloproject_generator.rb', line 9 def create_config template 'config/environments/production.rb' copy_file('config/environments/production.rb', 'config/environments/staging.rb') update_application_rb create_file('config/locales/fr.yml', "--\nfr: {}\n") rescue StandardError => e warn("[Modulorails] Error: cannot generate Moduloproject configuration: #{e.}") end |