Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Generate filenames without digest in case of cachebust none or soft

  • Loading branch information...
commit d23316ebdadabfe15d817770ae5ea96e1fa13e75 1 parent 01473c8
Alex Ernst authored ixti committed
Showing with 6 additions and 1 deletion.
  1. +6 −1 lib/jekyll/assets_plugin/asset_file.rb
View
7 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
Please sign in to comment.
Something went wrong with that request. Please try again.