Sha256: b6e3a3575dbaa7b4da344167d96d525ef90f54417187470e6bf0499fbeb2a206
Contents?: true
Size: 868 Bytes
Versions: 1
Compression:
Stored size: 868 Bytes
Contents
require 'rails/generators' module Kuhsaft module Assets class Install < Rails::Generators::Base source_root(File.join(Kuhsaft::Engine.root, '/lib/templates/kuhsaft/assets')) def copy_customizations custom_css_folder = 'app/assets/stylesheets/kuhsaft/' custom_js_folder = 'app/assets/javascripts/kuhsaft/' empty_directory custom_css_folder empty_directory custom_js_folder copy_file 'customizations.css.sass', "#{custom_css_folder}/customizations.css.sass" copy_file 'customizations.js.coffee', "#{custom_js_folder}/customizations.js.coffee" inject_into_file 'config/environments/production.rb', :after => /config\.assets\.precompile.*$/ do "\n config.assets.precompile += %w( kuhsaft/cms/customizations.css kuhsaft/cms/customizations.js )" end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
kuhsaft-1.2.8 | lib/generators/kuhsaft/assets/install_generator.rb |