Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
add asset manifest files and update install generator
Browse files Browse the repository at this point in the history
  • Loading branch information
citrus committed Mar 12, 2012
1 parent 86af25e commit fc2079a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
1 change: 1 addition & 0 deletions app/assets/javascripts/spree_variant_options.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
//= require_tree ./store
3 changes: 3 additions & 0 deletions app/assets/stylesheets/spree_variant_options.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/*
*= require store/variant_options
*/
5 changes: 2 additions & 3 deletions lib/generators/spree_variant_options/install_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,11 @@ def copy_migrations
end

def add_javascripts
append_file "app/assets/javascripts/store/all.js", "//= require store/product_variant_options\n"
append_file "app/assets/javascripts/store/all.js", "//= require store/variant_options\n"
append_file "app/assets/javascripts/store/all.js", "//= require spree_variant_options\n"
end

def add_stylesheets
inject_into_file "app/assets/stylesheets/store/all.css", "*= require store/variant_options\n", :before => /\*\//, :verbose => true
inject_into_file "app/assets/stylesheets/store/all.css", "*= require spree_variant_options\n", :before => /\*\//, :verbose => true
end

end
Expand Down
2 changes: 1 addition & 1 deletion lib/spree_variant_options/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module SpreeVariantOptions
class Engine < Rails::Engine

engine_name "spree_variant_options"

config.to_prepare do
#loads application's model / class decorators
Dir.glob File.expand_path("../../../app/**/*_decorator.rb", __FILE__) do |c|
Expand Down

0 comments on commit fc2079a

Please sign in to comment.