sindresorhus / gulp-rev

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

Give option to choose where hash is inserted in filename #168

Closed terrencewwong closed 8 years ago

terrencewwong commented 8 years ago

Currently the hash is prepended before the first dot character.

Ex.

foo.bar.baz -> foo-0123456789.bar.baz

I'd like an option that allows the hash to be prepended before the final dot character.

Ex.

foo.bar.baz -> foo.bar-0123456789.baz

This is useful if you're using dots in the file name that are not related to any extensions whatsoever. I'd like to add an option hash parameter to rev maybe rev({lastDot: true})

lukeed commented 8 years ago

See solution within #169