Skip to content

Instantly share code, notes, and snippets.

@BDQ
Created August 18, 2011 08:44
Show Gist options
  • Save BDQ/1153674 to your computer and use it in GitHub Desktop.
Save BDQ/1153674 to your computer and use it in GitHub Desktop.
require 'sprockets/asset_attributes'
Sprockets::AssetAttributes.class_eval do
alias_method :sprockets_path_with_fingerprint, :path_with_fingerprint
def path_with_fingerprint(digest)
if Rails.env.development?
pathname.to_s
else
sprockets_path_with_fingerprint(digest)
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment