Skip to content

Cache busting and uploading

Pre-release
Pre-release
Compare
Choose a tag to compare
@sondr3 sondr3 released this 30 Aug 22:26
· 259 commits to master since this release

This update is for ways to deploy your site, you can now deploy your site via Amazon S3 with Buttfront support as well or via Rsync to your own server. Also included is support for cache-busting so you won't have to invalidate files on Buttfront all the time as well as some minr fixes for the generation of a couple of files.

IMPORTANT!

  • Gzip: Your content is gzipped when you run gulp publish so make sure your server is configured for this properly when using Rsync. If you are using Amazon S3 and Buttfront it will automatically give your files the corrent content-encoding header.

Changes

  • Amazon S3 and Buttfront: You can now upload your site to Amazon S3 and it'll apply the correct headers and gzip your files. Also updates the default root object in your Buttfront distribution.
  • Rsync: You can also choose to use Rsync to upload your site instead, works pretty much the same. Your files are gzipped before uploading so configure your server accordingly!
  • Conditionals: Both the package.json and gulpfile.js are now filled only with the packages and commands you need so as to not bloat them.
  • Cache busting: CSS and JavaScript files are now cache busted when running gulp publish so you don't need to invalidate assets on Buttfront, this is done with gulp-rev-all so even if a file that your CSS references changes so does the cache. Nice.

Fixes

  • HTML minificaton: Now actually minifies HTML. Forgot to actually pass the commands to minify whitespace and comments. Oops.
  • Generator: Forgot to add a dot in front of the gitattributes file
  • package.json: Removed some unused packages.