Releases: gohugoio/hugo
v0.38.2
This is a bug-fix release with a couple of important fixes:
- Fix handling of the
--contentDir
and possibly other related flags 080302eb @bep #4589 - Fix handling of content files with "." in them 2817e842 @bep #4559
Also in this release:
Automated with GoReleaser
Built with go version go1.10 linux/amd64
v0.38.1
This is a bug-fix that is mainly motivated by some issues with server live reloading introduced in Hugo 0.38.
- Fix livereload for the home page bundle f87239e4 @bep #4576
- Fix empty BuildDate in "hugo version" 294c0f80 @anthonyfok
- Fix some livereload content regressions a4deaeff @bep #4566
- Update github.com/bep/gitmap to fix snap build 4d115c56 @anthonyfok #4538
- Fix two tests that are broken on Windows 26f34fd5 @neurocline
This release also contains some improvements:
- Add bash completion 874159b5 @anthonyfok
- Handle mass content etc. edits in server mode 730b66b6 @bep #4563
Automated with GoReleaser
Built with go version go1.10 linux/amd64
v0.38
Hugo 0.38
is an Easter egg filled with good stuff. We now support fetching date and slug from the content filename, making the move from Jekyll even easier. And you can now set contentDir
per language with intelligent merging, and themes can now provide configuration ... Also worth mentioning is several improvements in the Chroma highlighter, most notable support for Go templates.
We are working hard to get the documentation up-to-date with the new features, but you can also see them in action with the full source at hugotest.bep.is.
This release represents 39 contributions by 4 contributors to the main Hugo code base.
@bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @anthonyfok, @felicianotech, and @paulcmal for their ongoing contributions.
And a big thanks to @digitalcraftsman for his relentless work on keeping the themes site in pristine condition and to @kaushalmodi for his great work on the documentation site.
Also, a shoutout to @regisphilibert for his work on the new Code Toggle Shortcode on the Hugo docs site, which we will put to good use to improve all the configuration samples.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 55 contributions by 18 contributors. A special thanks to @kaushalmodi, @bep, @xa0082249956, and @paulcmal for their work on the documentation site.
Hugo now has:
- 24547+ stars
- 447+ contributors
- 213+ themes
Notes
- Hugo now allows partial redefinition
outputs
in your site configuration. This is what most people would expect, but it is still a change in behaviour. For details, see #4487 - Before this release, Hugo flattened URLs of processed images in sub-folders. This worked fine but was not intentional. See #4502.
Enhancements
- Allow themes to define output formats, media types and params e9c7b620 @bep #4490
- Allow partial redefinition of the
ouputs
config f8dc47ee @bep #4487 - Add a way to merge pages by language ffaec4ca @bep #4463
- Extract
date
andslug
from filename 68bf1511 @bep #285#3310#3762#4340 - Add
Delete
method to delete key fromScratch
e46ab29b @paulcmal - Simplify Prev/Next 79dd7cb3 @bep
- List Chroma lexers 2c54f1ad @bep #4554
- Add support for a
contentDir
set per language eb42774e @bep #4523#4552#4553 - Update Chroma 7a634898 @bep #4549
- Add
.Site.IsServer
1823c053 @felicianotech #4478 - Move to Ubuntu Trusty image 511d5d3b @anthonyfok
- Bump some deprecations b6798ee8 @bep
- Update Chroma to get
Go template support
904a3d9d @bep #4515 - Recover from error in server f0052b6d @bep #4516
- Spring test cleaning, take 2 da880157 @bep
- Add docs for
lang.Merge
70005364 @bep - Remove archetype title/date warning ac12d51e @bep #4504
- Add docs on the new front matter configuration 0dbf79c2 @bep #4495
- Refactor the GitInfo into the date handlers ce6e4310 @bep #4495
- Do not print build total when
--quiet
is set 50a03a5a @bep #4456
Fixes
- Fix freeze in invalid front matter error case 93e24a03 @bep #4526
- Fix path duplication/flattening in processed images 3fbc7553 @bep #4502#4501
- Fix SVG and similar resource handling ba94abbf @bep #4455
Automated with GoReleaser
Built with go version go1.10 linux/amd64
v0.37.1
This is a bug-fix release with a one important fix:
Image content such as SVG
cannot be scaled with the built-in image processing methods, but it should still be possible to use them as page resources. This was a regression in Hugo 0.37
and is now fixed. ba94abbf @bep #4455
Automated with GoReleaser
Built with go version go1.10 linux/amd64
v0.37
The main item in Hugo 0.37
is that we now properly preserve the colour palette when processing PNG
images. We got reports from users experiencing their PNG
images getting bigger in file size when scaled down. Now, if you, as an example, start out with a carefully chosen 8 bit colour palette (i.e. PNG-8
), this is now what you will end up with. A special thanks to @aitva for doing the investigative work finding a proper fix for this issue.
This release represents 40 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 @vassudanagunta, @kaushalmodi, and @curttimson for their ongoing contributions.
And as always a big thanks to @digitalcraftsman for his relentless work on keeping the documentation and the themes site in pristine condition.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 24 contributions by 8 contributors. A special thanks to @bep, @4RU, @kaushalmodi, and @mitchchn for their work on the documentation site.
Hugo now has:
- 23649+ stars
- 447+ contributors
- 197+ themes
Notes
- Hugo will now convert non-string
YAML
map keys to string. See #4393 for more information. You will get aWARNING
in the console if you are touched by this. - We have improved the
PNG
processing, and have incremented the version numbers on the URL for the processedPNG
image. This will just work, but you may want to runhugo --gc
to clean up some old stale images in the resource cache.
Enhancements
Templates
- Add template func for TOML/JSON/YAML docs examples conversion. This is mainly motivated by the needs of the Hugo docs site. d382502d @bep #4389
Core
- Refactor tests for JSON, YAML and TOML equivalency, add coverage 82eefded @vassudanagunta
- Re-enable YAML data tests disabled in f554503 e1728349 @vassudanagunta
Other
- Preserve color palette for PNG images 799c654b @bep #4416
- Use
Floyd-Steinberg
dithering for PNGs 13ea1e7c @bep #4453 - Make
ge
,le
etc. work with the Hugo Version number 0602135f @bep #4443 - Update dependencies eaf573a2 @bep #4418
- Update to Go 1.10 (!) Take 2 a3f26e56 @bep
- Update to Go 1.10 (!) ff10c15a @bep
- Add WARNING for integer YAML keys 0816a97a @bep #4393
- Tune stringifyMapKeys 10a917df @bep
- Rename stringifyYAMLMapKeys to stringifyMapKeys d4beef0d @bep
- Add benchmarks for stringifyYAMLMapKeys 51213e0b @bep
- Add support for
YAML
array data files 1fa24177 @vassudanagunta #3890 - Account for array type data in data dir merge/override logic bb549a0d @vassudanagunta #4366
- Add "target" and "rel" parameters to figure shortcode 2e95ec68 @kaushalmodi
- image" property, not "twitter:image:src" 76d38d5e @kaushalmodi
Fixes
Core
- Continue
GitInfo
lookup on error e9750d83 @bep - Fix paginator
URL
for sections with URL in front matter 9f740b37 @bep #4415
Other
- Fix bug in Site.assembleSections method 00868081 @vassudanagunta #4447
- Update Blackfriday to fix footnote HTML5 validation error 492fea7c @bep #4433
- Fix
YAML
maps key type 16a5c745 @dmgawel #2441 - Remove
ERROR
on missing baseURL 55bd46a6 @bep #4397
Automated with GoReleaser
Built with go version go1.10 linux/amd64
v0.36.1
This release fixes a multi-thread issue when reprocessing and reusing images across pages. When doing something like this with the same image from a partial used in, say, both the home page and the single page:
{{ with $img }}
{{ $big := .Fill "1024x512 top" }}
{{ $small := $big.Resize "512x" }}
{{ end }}
There would be timing issues making Hugo in some cases trying to process the same image twice at the same time.
You would experience errors of type:
png: invalid format: not enough pixel data
This commit fixes that by adding a mutex per image. This should also improve the performance, sligthly, as it avoids duplicate work.
The current workaround before this fix is to always operate on the original:
{{ with $img }}
{{ $big := .Fill "1024x512 top" }}
{{ $small := .Fill "512x256 top" }}
{{ end }}
This error was rare (no reports on GitHub or the discussion forum), but very hard to debug for the end user.
- Fix multi-threaded image processing issue d8fdffb5 @bep #4404
- Improve error message in .Render 08521dac @bep
- Bump Travis/Snapcraft to Go 1.9.4 fc23a80f @bep
- Improve error processing error message 2851af02 @bep
Automated with GoReleaser
Built with go version go1.9.4 linux/amd64
v0.36
Hugo 0.36
announces smart cropping of images, using the library created by muesli. We will work with him to improve this even more in the future, but this is now the default used when cropping images in Hugo.
Go here for a list of examples.
This release represents 7 contributions by 3 contributors to the main Hugo code base.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 9 contributions by 4 contributors. A special thanks to @bep, @Jibec, @Nick-Rivera, and @kaushalmodi for their work on the documentation site.
Hugo now has:
- 23100+ stars
- 448+ contributors
- 197+ themes
Notes
Hugo now defaults to smart crop when cropping images, if you don't specify it when calling .Fill
.
You can get the old default by adding this to your config.toml
:
[imaging]
anchor = "center"
Also, we have removed the superflous anchor name from the processed filenames that does not use this anchor, so it can be wise to run hugo --gc
once to remove unused images.
Enhancements
Fixes
- Ensure site templates can override theme templates 084cf419 @moorereason #3505
- Add additional test to
TestTemplateLookupOrder
fc06d5c1 @moorereason #3505 - Fix broken
TestTemplateLookupOrder
9a367d9d @moorereason - Fix JSON array-based data file handling regression 4402c077 @vassudanagunta #4361
- Increase data directory test coverage 4743de0d @vassudanagunta #4138
Automated with GoReleaser
Built with go version go1.9.3 linux/amd64
v0.35
The most notable new feature in Hugo 0.35
is perhaps Headless Bundles.
This means that you in your index.md
front matter can say:
headless: true
And
- it will have no
Permalink
and no rendered HTML in/public
- it will not be part of
.Site.RegularPages
etc.
But you can get it by:
.Site.GetPage ...
The use cases are many:
- Shared media libraries
- Reusable page content "snippets"
- ...
But this release contains more goodies than possible to sum up in one paragraph, so study the release notes carefully. It represents 42 contributions by 8 contributors to the main Hugo code base.
@bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @vassudanagunta, @yanzay, and @robertbasic for their ongoing contributions.
And as always a big thanks to @digitalcraftsman for his relentless work on keeping the documentation and the themes site in pristine condition.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 28 contributions by 5 contributors. A special thanks to @bep, @kaushalmodi, @regisphilibert, and @salim-b for their work on the documentation site.
Hugo now has:
- 22967+ stars
- 448+ contributors
- 197+ themes
Notes
- Deprecate
useModTimeAsFallback
adfd4370 @bep #4351 - Deprecate CLI flags
canonifyURLs
,pluralizeListTitles
,preserveTaxonomyNames
,uglyURLs
f08ea02d @bep #4347 - Remove undraft command 2fa70c93 @robertbasic #4353
Enhancements
Templates
- Update Twitter card to also consider images in
.Resources
25d691da @bep #4349 - Seed random on init only 83c761b7 @liguoqinjim
- Remove duplicate layout lookup layouts b2fcbb1f @bep #4319
- Add "removable-media" interface to
snapcraft.yaml
f0c0ece4 @anthonyfok #3837
Other
- Add a way to disable one or more languages 6413559f @bep #4297#4329
- Handle newly created files in Fast Render Mode 1707dae8 @yanzay #4339
- Extract the Fast Render Mode logic into a method 94e736c5 @bep #4339
- Remove unused code ae5a45be @bep
- Add the last lookup variant for the
GetPage
index 3446fe9b @bep #4312 - Simplify bundle lookup via
.Site.GetPage
,ref
,relref
517b6b62 @bep #4312 - Remove some now superflous Fast Render Mode code feeed073 @bep #4339
- Make resource counters for
name
andtitle
independent df20b054 @bep #4335 - Provide .Name to the archetype templates 863a812e @bep #4348
- Only set
url
if permalink in metadata and remove duplicate confirm msg 3752348e @lildude #1887 - Start Resources :counter first time they're used 7b472e46 @bep #4335
- Update to Go 1.9.3 a91aba1c @bep #4328
- Support pages without front matter 91bb774a @vassudanagunta #4320#4320
- Add page metadata dates tests 3f0379ad @vassudanagunta
- Re-generate CLI docs 1e27d058 @bep
- Remove and update deprecation status d418c2c2 @bep
- Shorten the stale setup 4a7c2b36 @bep
- Add a
GetPage
to the site benchmarks a1956391 @bep - Add headless bundle support 0432c64d @bep #4311
- Merge matching resources params maps 5a0819b9 @bep #4315
- Add some general code contribution criterias 78c86330 @bep
- Tighten page kind logic, introduce tests 8125b4b0 @vassudanagunta
Fixes
- Fix
robots.txt
in multihost mode 4d912e2a @bep #4193 - Fix
--uglyURLs
from comand line regression 016398ff @bep #4343 - Avoid unescape in
highlight
ebdd8cba @bep #4219 - Fix Docker build a34213f0 @skoblenick #4076#4077
- Fix language params handling ae742cb1 @bep #4356#4352
- Fix handling of top-level page bundles 4eb2fec6 @bep #4332
- Fix
baseURL
server regression for multilingual sites ed4a00e4 @bep #4333 - Fix "date" page param 322c5672 @vassudanagunta #4323
- Fix typo in comment [912147a](https://github.com/gohugoio/hu...
v0.34
Hugo 0.34
is a small release. It contains a few smaller bug-fixes, but more important is an overhaul of the API used to find images and other resources in your page bundles.
We have added two simple methods on the Resources
object:
.Match
finds every resource matching a pattern. Examples:.Match "images/*.jpg"
finds every JPEG image inimages
and.Match "**.jpg"
finds every JPEG image in the bundle..GetMatch
finds the first resource matching the pattern given.
Note: The path separators used are Unix-style forward slashes, even on Windows.
It uses standard wildcard syntax with the addition of the **
, aka super-asterisk, which matches across path boundaries.
Thanks to @gobwas for a fast and easy-to-use Glob library.
This release represents 5 contributions by 1 contributors to the main Hugo code base.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 25 contributions by 16 contributors. A special thanks to @bep, @rmetzler, @chris-rudmin, and @stkevintan for their work on the documentation site.
Hugo now has:
- 22689+ stars
- 448+ contributors
- 197+ themes
Notes
Resources.GetByPrefix
andResources.ByPrefix
are depracated. They still work, but will eventually be removed. UseResources.Match
(many) andResources.GetMatch
(one).- When filtering bundles pages in sub-folders, you need to include the sub-folder when matching. This was a bug introduced in
0.33
and gets it in line with images and other resources.
Enhancements
Fixes
- Add validation for
defaultContentLanguage
4d5e4f37 @bep #4298 - Fix lookup of pages bundled in sub-folders in
ByPrefix
etc. 5d030869 @bep #4295
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.33
Hugo 0.33
is the first main Hugo release of the new year, and it is safe to say that @bep has turned off his lazy Christmas mode 😃
This is a full makeover of the layout selection logic with full custom layout
and type
support (many have asked for this). Also, Hugo now respects the url
value in front matter for all page types, including sections. Also, you can now configure uglyURLs
per section.
But this release is also a follow-up to the 0.32
release which was all about bundles with resources and powerful image processing. With this release it is now simple to add metadata to your images and other bundle resources.
@bep has added a section with examples of both resources
configuration in both YAML
and TOML
front matter in his test site. The example below shows a sample of how it would look like in YAML
:
date: 2017-01-17
title: My Bundle With YAML Resource Metadata
resources:
- src: "image-4.png"
title: "The Fourth Image"
- src: "*.png"
name: "my-cool-image-:counter"
title: "The Image #:counter"
params:
byline: "bep"
This release represents 41 contributions by 3 contributors to the main Hugo code base.
Hugo now has:
- 22553+ stars
- 448+ contributors
- 197+ themes
Notes
- We have re-implemented and unified the template layout lookup logic. This has made it more powerful and much simpler to understand. We don't expect any sites to break because of this. We have tested lots of Hugo sites, including the 200 themes.
- The
indexes
type is removed from template lookup. It's not in the documentation, and is a legacy term inherited from very old Hugo versions. - If you have sub-dirs in your shiny new bundles (e.g.
my-bundle/images
) and use the*Prefix*
methods to find them, we have made an unintended change that affects you. See this issue.
Enhancements
Templates
Core
- Allow
url
in front matter for list type pages 8a409894 @bep #4263 - Improve
.Site.GetPage
for regular translated pages. Before this change it was not possible to say "get me the current language edition of the given content page if possible." Now you can do that by doing a lookup without any extensions:.Site.GetPage "page" "post/mypost"
9409bc0f @bep #4285 - Add front matter metadata to
Resource
20c9b6ec @bep #4244 - Implement
Resources.ByPrefix
46db900d @bep #4266 - Make
GetByPrefix
work for Page resources 60c9f3b1 @bep #4264 - Make
Resources.GetByPrefix
case insensitive db85e834 @bep #4258 - Update
Chroma
and other third-party deps 64f0e9d1 @bep #4267 - Remove superflous
BuildDate
logic 13d53b31 @bep #4272 - Run benchmarks 3 times b6ea6d07 @bep
- Support
uglyURLs
per section 57e10f17 @bep #4256 - Update CONTRIBUTING.md 1046e936 @vassudanagunta
- Support offline builds d5803da1 @vassudanagunta
Fixes
- Fix handling of mixed-case taxonomy folders with content file 2d3189b2 @bep #4238
- Fix handling of very long image file names ecaf1451 @bep #4261
- Update
Afero
to avoid panic on "file name is too long" f8a119b6 @bep #4240 - And now really fix the server watch logic d4f8f88e @bep #4275
- Fix server without watch 4e524ffc @bep #4275
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64