Sha256: 40a704d969f27000cbd3fa0183a55b1d618f9410381d1b20456ea51d0b622290
Contents?: true
Size: 1.13 KB
Versions: 2
Compression:
Stored size: 1.13 KB
Contents
module HappySeed module Generators class BootstrapGenerator < Rails::Generators::Base source_root File.expand_path('../templates', __FILE__) def update_application_haml gem 'bootstrap-sass' gem 'modernizr-rails' gem 'meta-tags', :require => 'meta_tags' Bundler.with_clean_env do run "bundle install" end remove_file 'app/views/layouts/application.html.erb' remove_file 'app/assets/javascripts/application.js' remove_file 'app/helpers/application_helper.rb' remove_file 'app/assets/stylesheets/application.css' directory 'app' directory 'lib' directory 'docs' inject_into_file 'config/application.rb', before: "end\nend\n" do <<-'RUBY' config.action_view.field_error_proc = Proc.new { |html_tag, instance| html_tag } config.generators do |g| g.stylesheets = false g.scaffold_controller "scaffold_controller" end RUBY end if File.exists?( File.join( destination_root, ".env" ) ) append_to_file ".env", "GOOGLE_ANALYTICS_SITE_ID=\n" end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
happy_seed-0.0.11 | lib/generators/happy_seed/bootstrap/bootstrap_generator.rb |
happy_seed-0.0.10 | lib/generators/happy_seed/bootstrap/bootstrap_generator.rb |