Last Updated: February 25, 2016
·
414
· tantaman

Renaming your assets after compilation

When deploying to S3 you can gzip your files ahead of time so they are served as gzipped.

This is a quick hack to revert files that were gzipped to have their original extension:

find dist/ -name "*.gz" -exec sh -c 'mv "{}" `echo "{}" | sed s/\.gz$//` ' \;

Something that is integrated into your build tool would be more advisable but this gets the job done.