require 'rails/generators' require 'chaltron/banner' module Chaltron # Install a skeleton application class InstallGenerator < Rails::Generators::Base desc 'Install a chaltron skeleton application' source_root File.expand_path('../templates', __FILE__) class_option :interactive, type: :boolean, desc: 'Run interactive configuration.', default: true def disclaimer print_banner if options.interactive? exit unless yes?('Are you sure you want to continue? [yes/NO]') end end def gemfile gem 'bootstrap_form', git: 'https://github.com/bootstrap-ruby/rails-bootstrap-forms.git', branch: 'master' Bundler.with_clean_env do run 'bundle install' end end def db_migrations rake 'chaltron_engine:install:migrations' end def db_seed append_file 'db/seeds.rb' do <