Permalink
Browse files

Generate filenames without digest in case of cachebust none or soft

  • Loading branch information...
Alex Ernst authored and ixti committed Feb 16, 2013
1 parent 01473c8 commit d23316ebdadabfe15d817770ae5ea96e1fa13e75
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/jekyll/assets_plugin/asset_file.rb
@@ -14,7 +14,12 @@ def initialize site, asset
def destination dest
- File.join(dest, @site.assets_config.dirname, @asset.digest_path)
+ case @site.assets_config.cachebust
+ when :none then File.join(dest, @site.assets_config.dirname, @asset.logical_path)
+ when :soft then File.join(dest, @site.assets_config.dirname, @asset.logical_path)
+ when :hard then File.join(dest, @site.assets_config.dirname, @asset.digest_path)
+ else raise "Unknown cachebast strategy: #{@site.assets_config.cachebust}"
+ end
end

0 comments on commit d23316e

Please sign in to comment.