diff options
author | Joshua Peek <josh@joshpeek.com> | 2011-03-29 18:05:23 -0500 |
---|---|---|
committer | Joshua Peek <josh@joshpeek.com> | 2011-03-29 18:05:23 -0500 |
commit | db3e310d6b327b2b58cfbc0318abd3b4ddca5e30 (patch) | |
tree | abc6b2426de401a93b9517be8c6ac8d2ffdff0e3 /railties | |
parent | 8e4d0b118bbcdfe6b41d15400d092c871c5a1114 (diff) | |
download | rails-db3e310d6b327b2b58cfbc0318abd3b4ddca5e30.tar.gz rails-db3e310d6b327b2b58cfbc0318abd3b4ddca5e30.tar.bz2 rails-db3e310d6b327b2b58cfbc0318abd3b4ddca5e30.zip |
Change back to /assets prefix
Diffstat (limited to 'railties')
-rw-r--r-- | railties/lib/rails/engine.rb | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb index 85f7d22fc9..79d48889c9 100644 --- a/railties/lib/rails/engine.rb +++ b/railties/lib/rails/engine.rb @@ -444,7 +444,7 @@ module Rails engine = self routes.append do if engine.config.use_sprockets - routes.add_route(engine.assets, {}, {}, {}, nil, false) + routes.add_route(engine.assets, {:path_info => "/assets"}, {}, {}, nil, false) end end @@ -453,15 +453,12 @@ module Rails def self.default_sprockets_paths [ - "app/assets", - "app/assets/javascripts", - "app/assets/stylesheets", - "vendor/plugins/*/app/assets", - "vendor/plugins/*/app/assets/javascripts", - "vendor/plugins/*/app/assets/stylesheets", - "vendor/plugins/*/assets", - "vendor/plugins/*/assets/javascripts", - "vendor/plugins/*/assets/stylesheets" + "app/javascripts", + "app/stylesheets", + "vendor/plugins/*/app/javascripts", + "vendor/plugins/*/app/stylesheets", + "vendor/plugins/*/javascripts", + "vendor/plugins/*/stylesheets" ] end @@ -475,7 +472,7 @@ module Rails require 'sprockets' env = Sprockets::Environment.new(root.to_s) - env.static_root = root.join("public") + env.static_root = root.join("public/assets") self.class.default_sprockets_paths.each do |pattern| Dir[root.join(pattern)].each do |dir| |