sindresorhus / gulp-rev

Static asset revisioning by appending content hash to filenames: `unicorn.css` → `unicorn-d41d8cd98f.css`
MIT License
1.54k stars 218 forks source link

Add hashLength and salt options to rev() #101

Closed mrkipling closed 9 years ago

mrkipling commented 9 years ago

Both are optional.

hashLength allows you to modify the length of the hash (defaults to 8, which is the current hard-coded value).

salt is an optional string that is applied to every file when generating a hash, in addition to the file contents. This will result in a different md5 hash being created. It is useful if you want to invalidate the current cache of files by changing the cachebusting hashes, without actually changing the contents of the files. You could also use a different salt per deployment for example if the files needed to exist side-by-side.

sindresorhus commented 9 years ago

No thanks