Class: Boring::Figjam::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Boring::Figjam::InstallGenerator
- Defined in:
- lib/generators/boring/figjam/install/install_generator.rb
Instance Method Summary collapse
Instance Method Details
#add_figjam_gem ⇒ Object
8 9 10 11 12 13 14 |
# File 'lib/generators/boring/figjam/install/install_generator.rb', line 8 def add_figjam_gem say 'Adding figjam gem', :green Bundler.with_unbundled_env do run 'bundle add figjam' end end |
#configure_figjam ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/generators/boring/figjam/install/install_generator.rb', line 16 def configure_figjam say 'Configuring figjam', :green Bundler.with_unbundled_env do run 'bundle exec figjam install' end FileUtils.cp('config/application.yml', 'config/application.yml.sample') unless File.exist?('.gitignore') create_file '.gitignore' end insert_into_file('.gitignore', "\n/config/application.yml\n") end |