files produced by asset:precompile don't match urls generated by stylesheet_link_tag (missing digest) in minimal rails 4 site

后端 未结 2 1117
面向向阳花
面向向阳花 2020-12-31 09:54

I\'m using Ruby 2.0.0-p247 and Rails 4.0.0

If I make a minimal Rails 4 site like this:

rails new minimal
cd minimal
rails g         


        
2条回答
  •  感动是毒
    2020-12-31 10:23

    I was able to resolve asset links not including the digest by bumping the asset version number.

         # Version of your assets, change this if you want to expire all your assets
    -    config.assets.version = '1.0'
    +    config.assets.version = '2.0'
    

    You'll find this either in config/application.rb if you're upgrading or in the newer location config/initializers/asset.rb

提交回复
热议问题