Sha256: 3a0344c4b8d22c44cde0f76002ed5c177065a448ae5b4bdddcb3eac5b86e78b1
Contents?: true
Size: 476 Bytes
Versions: 14
Compression:
Stored size: 476 Bytes
Contents
require 'fileutils' desc "Create nondigest versions of all ckeditor digest assets" task "assets:precompile" do fingerprint = /\-([0-9a-f]{32}|[0-9a-f]{64})\./ for file in Dir["#{File.join('public', Rails.configuration.assets.prefix)}/ckeditor/**/*"] next unless file =~ fingerprint nondigest = file.sub fingerprint, '.' if !File.exist?(nondigest) or File.mtime(file) > File.mtime(nondigest) FileUtils.cp file, nondigest, verbose: true end end end
Version data entries
14 entries across 14 versions & 2 rubygems