Compressing images

I'm currently doing a Wordpress -> Middleman shuffle for our team blog at work. This came from a review of all our infrastructure and where we could do some cost cutting. We decided to decommission the Wordpress site, as the content was primarily flat, (just blog posts), and we could host that for free on Github pages.

Most of the build was pretty straight forward. As a quick run down I chose to use middleman as I was already familiar with it, I added the middleman-blog and middleman-deploy gems to make my life easier and translated all the posts to markdown using the wp2middleman command line tool. There are plenty of good tutorials out there that run you through this.

When it came to transferring over the media it became important to me to keep the size of the images down to a minimum. Page weights are getting heavier these days (imo) unnecessarily. So when asking in the wonderful Front End London Slack about what I could use for batch image compression I received the following responses:

Thanks to Patrick, Phil, Ian, Dan and Arran.

Then the lovely Charlotte said:

@rumyra: I recently took a day at work and investigated all the available tools out there. ImageOptim CLI is your best bet as it uses both lossy and lossless compression, actually works and is free. The CLI uses more tools than just imageoptim, so all the bases are covered. The repo has some ace stats too

Sums it up nicely - I'm sold!