Why are my CSS/JS changes not showing up in my Rails app?


When using the Ruby buildpack, this checks to see whether assets were compiled locally and committed to git for each deploy by looking for a manifest.yml file in the repo. This is shown by the following message in the build log:

Detected manifest file, assuming assets were compiled locally

This usually indicates that rake assets:precompile has been run locally and then those files were committed to git. Heroku interprets this to mean that you'd rather precompile your assets manually, which some users like to do for faster builds. See https://devcenter.heroku.com/articles/rails-asset-pipeline#compiling-assets-locally

To stop this happening you need to remove the manifest.yml from public/assets, commit that change to git and then redeploy. Rails 4 uses a file called public/assets/manifest-<md5 hash>.json instead. More recent versions use public/assets/.sprockets-manifest-<md5 hash>.json (note the dot . indicating it may be hidden by default on your machine).