Image Processing Galore! (Hugo 0.58.0 release)

https://gohugo.io/news/0.58.0-relnotes/

Featured Image for Image Processing Galore!

Hugo 0.58 adds the long sought after Exif (docs) method on image and a bunch of useful image filters (docs), courtesy of @disintegration’s great Gift image library.

This means that you now can do variations of this:

{{ $blurryGrayscale := $myimage.Resize "300x200" | images.Filter images.Grayscale (images.GaussianBlur 8) }}
{{ $exif := $myimg.Exif }}

It’s worth noting that the issue that enabled/triggered the implementation of the above was the simplifications needed to fix #5903, which makes sure that type information is preserved when processed via Hugo Pipes . E.g. you can now do:

{{ ($myimg | fingerprint ).Width }}

And it works as expected.

This release is also built with the brand new Go 1.13 which means that it’s also the fastest Hugo version to date.

This release represents 39 contributions by 5 contributors to the main Hugo code base.@bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @niklasfasching, @vazrupe, and @jakejarvis for their ongoing contributions.

And a big thanks to @digitalcraftsman and @onedrawingperday for their relentless work on keeping the themes site in pristine condition and to @kaushalmodi for his great work on the documentation site.

Many have also been busy writing and fixing the documentation in hugoDocs, which has received 8 contributions by 8 contributors . A special thanks to @jacebenson, @digitalcraftsman, @jernst, and @rgwood for their work on the documentation site.

Hugo now has:

Notes

  • home.Pages now behaves like all the other sections, see #6240. If you want to list all the regular pages, use .Site.RegularPages .
  • We have added some new image filters to Hugo’s image processing. This also means that we have consolidated the resize operations to use the one gift library (from the same developer as the one we used before). The operations work as before, but one difference is that we no longer embed color profile information in PNG images, but this should also be a more portable solution. Software that supports color profiles will assume that images without an embedded profile are in the sRGB profile. Software that doesn’t support color profiles will use the monitor’s profile, which is most likely to be sRGB as well.
  • We have improved the file cache logic for processed images and only stores them once when the same image is bundled in multiple languages. This means that you may want to run hugo --gc to clean your image cache.

Enhancements

Templates

Core

Other

Fixes

Core

Other

I haven’t messed with image manipulation, but happy to see it simplified and more features. :slight_smile:

https://gohugo.io/news/0.58.1-relnotes/

This is a bug-fix release with a couple of important fixes.

https://gohugo.io/news/0.58.2-relnotes/

This is a bug-fix release with a couple of important fixes.

https://gohugo.io/news/0.58.3-relnotes/

This is a bug-fix release with a couple of important fixes.